Euclidean Distance implementations in multiple programming languages for CME 3402 Assignment 1.
The goal of this assignment is to calculate the Euclidean Distance between two patient records from the diabetes dataset.
The implementations are written in multiple programming languages to demonstrate understanding of syntax, paradigms, and programming concepts across different languages.
- JavaScript
- Perl
- COBOL
- F#
- Rust
- Python
- Ruby
- Go
- APL
- Common Lisp
- Prolog
The following formula is used:
d = √(Σ(xᵢ - yᵢ)²)
In this project, the records contain 8 dimensions corresponding to patient health information from the diabetes dataset.
GROUP_22_2022510137_2023510064_2022510124.js
GROUP_22_2022510137_2023510064_2022510124.pl
GROUP_22_2022510137_2023510064_2022510124.cob
GROUP_22_2022510137_2023510064_2022510124.fs
GROUP_22_2022510137_2023510064_2022510124.rs
GROUP_22_2022510137_2023510064_2022510124.py
GROUP_22_2022510137_2023510064_2022510124.rb
GROUP_22_2022510137_2023510064_2022510124.go
GROUP_22_2022510137_2023510064_2022510124.apl
GROUP_22_2022510137_2023510064_2022510124.lsp
GROUP_22_2022510137_2023510064_2022510124.pro
README.md
Each program contains two sample patient records directly defined inside the source code.
Example output:
Euclidean Distance: 66.903
This assignment demonstrates Euclidean Distance calculation across different programming paradigms:
| Language | Paradigm |
|---|---|
| JavaScript | Imperative / Multi-paradigm |
| Perl | Scripting / Imperative |
| COBOL | Procedural |
| F# | Functional |
| Rust | Systems Programming |
| Python | Multi-paradigm |
| Ruby | Object-Oriented |
| Go | Concurrent / Procedural |
| APL | Array-Oriented |
| Common Lisp | Functional |
| Prolog | Logical / Declarative |
- No external libraries were used for the distance calculation.
- Variables are intentionally easy to modify for code review sessions.
- The implementations follow the assignment requirements provided by the instructor.
- All implementations were tested and produce consistent Euclidean Distance results.
Dokuz Eylül University
Faculty of Engineering
Department of Computer Engineering
CME 3402 — Concepts of Programming Languages