Friday, September 12, 2014

Scala: From Zero to Algorithms

0 comments
Today, I will introduce somethings basic of Scala, and solve some basical algorithms using Scala with you guys. I will continue the rests in next some articles.

First, I want to introdue that Scala is functional programming + object oriented programming. How you guys differentiate procedures, methods and functions? Check out my opinion!

  • Procedure: A sequence of statements. such as assignments, tests, loops and invocations of sub procedures. These procedures are functions, which map arguments to return statements. 
  • Method: Something like procedure, however, it is belong to class or object. And can be public, private or protected. It is also can be overloaded. In order to use method, you call via a class or object. However, In my opinion, you cant use methods as parameters, or another type of variables. 
  • Function: You can google Scala functions, It is also a sequence of statements. However, It much more useful and flexible. You can use functions as other functions parameters, types of variables.
Read more here

Leave a Reply

 
All Tech News IN © 2011 DheTemplate.com & Main Blogger .