Posterous theme by Cory Watilo

Week 4

Comments on 7 Languages in 7 Weeks:

Scala

-          Allows integration with JJava

-          Runs on JVM

-          Syntax similar to Java

 

Martin Odersky

-          He wanted to combine functional and object-oriented programming

-          Twitter switched from ruby to scala

 

16

It was cool to see the same syntax as java since I have some experience in writing in java. I see where the functional programming comes in with the response back to the user

Self-Study

1)      Scala API - http://www.scala-lang.org/api/current/index.html#package

2)      Comparison of Scala and Java - http://blogs.oracle.com/sundararajan/entry/scala_for_java_programmers

3)      Val vs var - http://blog.sanaulla.info/2009/07/02/val-versus-var-in-scala/

17

Self Study

1)      How to use scala files - http://stackoverflow.com/questions/1284423/read-entire-file-in-scala

2)      Closure vs code block - http://www.javacodegeeks.com/2011/11/scala-tutorial-code-blocks-coding-style.html

 

Overall, I see the elements that scala uses from java. For instance, curly braces, print statements, loops, and the use of constructors. The actor paradigm is better in scala than in ruby. I thought it was great that scala uses the java libraries. The java libraries are huge. Why reinvent the wheel when there are libraries available and scala uses the java libraries, which I think is great. Scala seems to use less code than Java, I believe the lesser the code, the better. However, for someone that has used java before, the following syntax can get confusing:

Def doChore (chore: String)

In Java, I’m used to having the data type first then the name of the variable (String chore). It’s nice that the syntax is similar but it can get confusing.

 

 

 

Comments on Form + Code

 

 

Software influences design

They define form as visual and spatial structures

Codes serve three main purposes

                Communication, clarification, or obfuscation

Talk about code like Morse code, DNA, laws, and writing

Comparing algorithms to directions

                It has four qualities – there are many ways to write it, it requires assumptions, it includes decisions, and complex algorithms should be broken down

Pg 15 talks about the relationship between a human and a computer and how we can talk to each other. We use code that has words and punctuations that we can understand and when compiled a computer can understand it. Instructions for a computer must be very specific, unlike humans, computers cannot in something unless it is clearly stated.

Pg 25 – “writing code is one gateway for realizing these new forms. Learning to program and to engage the computer more directly with code opens the possibility of not only creating tools, but also systems, environments, and entirely new modes of expression”

Sketchpad to CAD to laser printer

The internet – led to the question … do we really need a central office?

Pg 31 – if ocmputers could be used to model what we know, then perhapswe could also use them to simulate what we don’t know

Crt to lcd to led

Repetition can have a powerful effect on the human body and psyche