Skip to content

further style tweaks to code on Getting Started page #369

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Dec 13, 2015
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions documentation/getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ If you are just starting to learn how to code, you will find that a large portio
As a first example, we use the standard "Hello, world!" program to demonstrate the use of the Scala tools without knowing too much about the language.

object HelloWorld {
def main(args: Array[String]) {
def main(args: Array[String]): Unit = {
println("Hello, world!")
}
}
Expand All @@ -49,13 +49,13 @@ The `scala` command starts an interactive shell where Scala expressions are inte
Type :help for more information.

scala> object HelloWorld {
| def main(args: Array[String]) = {
| def main(args: Array[String]): Unit = {
| println("Hello, world!")
| }
| }
defined module HelloWorld

scala> HelloWorld.main(Array.empty)
scala> HelloWorld.main(Array())
Hello, world!

scala>:q
Expand Down