Collection of Scheme language resources of the course (CE3104) Languages, Compilers and Interpreters focused on the functional programming paradigm.
The programming languages course introduces the four main programming paradigms and its most representative languages. The Scheme language is designed to be modeled using functional programming, that is, through the use of separate functions that together provide the solution to a problem.
Most of this material has been compiled from the book "Introducción a la programación con Scheme" by José Helo Guzmán and the notes of "Lenguajes y paradigmas de programación" page.
What's in this repository?
- Functions and Expressions.
- Data input/output.
- Conditionals.
- Iterations.
- Recursion and Applied Mathematics.
- List and Arrays.
- Trees and Graphs.
Prerequisites:You must have Git installed on your console.
-
On GitHub, go to the main page of the repository.
-
Under the name of the repository, click Clone or download.
-
In the Clone with HTTPs section, click to copy the repository cloning URL.
-
Open Git Bash.
-
Change the current working directory to the location where you want the cloned directory to be made.
-
Type 'git clone', and then paste the URL that you copied in Step 2.
$ git clone https://github.com/estalvgs1999/CE3104-Scheme.git
-
Press Enter. Your local clone will be created for CE3104-Scheme.
-
Now you can access the examples contained in this repository; but remember to be aware because I am constantly uploading new material.
To run the examples you need a code editor and a Scheme compiler. I recommend DrRacket that you can download from the [official website](https://download.racket-lang.org/) or install from the Ubuntu PPA. For this you must follow these steps:
- Open your terminal
Ctrl + Alt + T
. - Enter this command to add the Racket PPA:
$ sudo add-apt-repository ppa:plt/racket
- Install it with this command:
$ sudo apt-get install racket
The reason for this project is to have resources and examples of the Scheme functional language, so you can consult them to learn or remember how that thing was done?
For example, the fibonacci series:
;; Fibonacci's Series Scheme implementation
(define (fib num)
(cond ((or (zero? num) (equal? num 1))
1 )
(else (+ (fib (- num 1)) (fib (- num 2))))
)
)
Esteban Alvarado - Computer Engineering Student - @estalvgs1999
I thank the teachers of the course:
- Ing. Marco Rivera Meneses from Programming Languages
- Ing. Marco Hernández Vásquez from Compilers and Interpreters
This project is licensed under the GNU General Public License v3.0 - see the LICENSE.md file for details