Programming Languages
Building Using Scratch
Scratch is a block based visual programming language. This is the link to my Scratch assignment https://scratch.mit.edu/projects/535439801. Problems
I had fun when building my assignment, but I ran into some problems. Most of the problems were due to carelessness and getting used to how the blocks were organized. The problem that took me the longest to find and solve was when it came to switching backdrops. I had wanted to use the woods backdrop in the beginning and end, but I couldn’t figure out why my characters weren’t appearing at the end. Turns out that I needed to think of the first woods scene as one block and the last woods scene as a separate block. I assumed they were the same just because the background was the same, but that led to problems with the program processing it when it ran. To fix that, the first woods backdrop was called ‘Woods 1’ and the second one was called ‘Woods 2’ when using the backdrop transition block. This experience helped me realize that just because something looked the same visually didn’t mean they could be labeled the same thing because they’re actually different events.
Similar To
Scratch felt closest to section 2.11 about Python. I could see that having a defined beginning and end to the commands in both Scratch and Python were really important. Without a beginning and end, the Python program would provide an error, or in Scratch, the characters would not do what I intended to happen. For instance in Scratch, whenever I forgot to add the block to change backdrops, my characters would be in the wrong scene. In both, I could also see that empty spaces didn’t affect the code. I saw that Scratch also had operation blocks which were really similar to section 2.10 about high level language, but I had not utilized them in my project. I found that I liked the Python section the best because it felt the easiest to read.
Types of Programming Languages
Programming languages fall into different types. These types are as follows: procedural, functional, object oriented, scripting and logic.
I had fun when building my assignment, but I ran into some problems. Most of the problems were due to carelessness and getting used to how the blocks were organized. The problem that took me the longest to find and solve was when it came to switching backdrops. I had wanted to use the woods backdrop in the beginning and end, but I couldn’t figure out why my characters weren’t appearing at the end. Turns out that I needed to think of the first woods scene as one block and the last woods scene as a separate block. I assumed they were the same just because the background was the same, but that led to problems with the program processing it when it ran. To fix that, the first woods backdrop was called ‘Woods 1’ and the second one was called ‘Woods 2’ when using the backdrop transition block. This experience helped me realize that just because something looked the same visually didn’t mean they could be labeled the same thing because they’re actually different events.
Similar To
Scratch felt closest to section 2.11 about Python. I could see that having a defined beginning and end to the commands in both Scratch and Python were really important. Without a beginning and end, the Python program would provide an error, or in Scratch, the characters would not do what I intended to happen. For instance in Scratch, whenever I forgot to add the block to change backdrops, my characters would be in the wrong scene. In both, I could also see that empty spaces didn’t affect the code. I saw that Scratch also had operation blocks which were really similar to section 2.10 about high level language, but I had not utilized them in my project. I found that I liked the Python section the best because it felt the easiest to read.
Types of Programming Languages
Programming languages fall into different types. These types are as follows: procedural, functional, object oriented, scripting and logic.
- Procedural languages execute a sequence of commands that lead to a result by using variables and loops.
- Functional languages are simpler syntactically.
- Object oriented languages solve problems by splitting it into a collection of parts.
- Scripting languages require little syntax and are typically not expected to be a full fledged programming language.
- Logic languages allow users to make declarative statements then allow the computer to reason the outcomes.
I think Python is the most popular language because it is easier to learn because of its simple syntax. Python, despite being easier, to learn is still relevant for web development, data analysis, and machine learning. Python is just more diverse purpose wise.
References
https://www.cprogramming.com/langs.html.
Comments
Post a Comment