Wednesday, June 10, 2015

Project Conclusion

As the semester winds up to an end, so too does my passion project. I would like to use this post as a way to reflect on my project as well as make connections to my bible class.

My initial goals for this project were to get an introduction to coding, begin writing code and become more equipped for computer science at university. I believe that in one way or another, I accomplished all of these goals. Code academy was a great tool to accomplishing my goals as it gave me a very convenient way to learn and experiment at the same time.

When considering the "throughlines" I have learned about in my bible class, I find that I am able to relate my project to them.

The first one which I found relates to my project is God worshiping. An aspect of God worshiping is celebrating who God is and having a sense of wonder towards God. When you begin to understand a bit more about the complexity of computer software it gives you a sense of wonder at the creativity that God has instilled in us. Someone had to make these languages all the other intricacies of computer science. This definitely gave me a deep sense of wonder.

One last one Which I would like to talk about is "Idolatry discerning." Computer science takes time and if you're doing it for a job or just because you enjoy it, I can see how it could become your number one priority in life. Anything given more importance than God is an idol, so in the future I will have to make sure to keep my priorities in line when dealing with computer science.

Tuesday, June 9, 2015

Program Two

Since the completion of the first program at code academy, I have started the second program. This program involves creating a choose your own adventure web game using what I have learned from Javascript in the first lesson.

I have found this to be quite fun so far and also very useful as it allows me the opportunity to utilize all I know about Javascript in the same project. It also acts as a good refresher of old concepts as when I need to do something involving something which I learned say a month prior, I am forced to go back and relearn things which I have forgotten.

More Progress

As I continued my course at code academy, a lot of the lessons were just simply combining concepts which I had already learned to make more complex code. This was fun and rewarding as I got to see most of what I had learned work together in new ways.

Next I learned about substrings and how to manipulate them. A substring is simply just part of a string. For example, in your email inbox, the first few lines of the email are displayed. This is a substring of the full string, the email. You can display a substring of a string by using the .substring(x,y) code after a string. The x is the place where you want the substring to start and the y is the place where you want the substring to end. Below is an example of a few substrings printed out using the console.log function.











Next I moved onto variables. Variables are a way to save values by declaring a name for it. This is done with the command "var" followed by the name which you are declaring for the variable, then an equals sign and finally the value. Below is a simple example of declaring a variable then printing it out.











Next I learned how to change a variables value. This is just as easy as redeclaring the variable as if it was a new one on a different line.

I have made a lot of progress on the fundamentals of Javascript and this after learning about variables, I actually finished the first Program on Javascript at codeacademy.

Progress

Despite the lack of posts on this blog, I have continued to learn and explore javascript for this project. I have had an unfortunate lack of motivation and an apathetic approach to posting on my blog as it is very time consuming and difficult to blog about my topic.

However, I do want to continue to share about the progress I am making on the course at code academy.

The next thing I learned about with Javascript is a big one and one which I find quite cool. It is comparisons and if statements. An if statement uses the word "if" and a following statement. If this statement is true, it will run the code in the following curly braces {} An example of this can be seen below.

The above if statement did something if the statement is true. I then learned how to make the computer do something if the statement was instead false. This is done by adding an "else" section. If the statement is not true, it will run the code inside the curly braces after the "else." An example can be seen below.

The next thing I learned on code academy was a bit about debugging. I was given several lines of incorrect code with mistakes in it. This code did not run properly. It was my task to fix the code so that it could run. It took me a bit to see all of the errors but I did get it eventually.

The next new thing which I learned involved the modulo or the "%." When this symbol is placed between two numbers, the computer divides the first number by the second and displays the remainder. To practice this, i was given the simple task of printing out the answers to some questions using a modulo using the console.log function. Some examples of using the modulo are down below.