Initial commit

This commit is contained in:
Inanc Gumus
2018-10-13 23:30:21 +03:00
commit cde4e6632c
567 changed files with 17896 additions and 0 deletions

View File

@ -0,0 +1,22 @@
# QUESTIONS: What's a variable?
* **Where does a variable live?**
* Hard Disk
* Computer Memory - *CORRECT*
* CPU
* **What do you use a variable's name for?**
* To be able to access it later - *CORRECT*
* It's just a label
* I don't need to use it
* **How to change the value of a variable?**
* By using its name - *CORRECT*
* By using its value
* By asking to Go
* **After its declaration can you change the variable's type?**
* Yes : Go is dynamically-typed
* No : Go is statically-typed - *CORRECT*
* Both: Go supports both of them

View File

@ -0,0 +1,21 @@
## Which statement do you need to use for declaring variables?
* name int
* vars string name
* var name integer
* var width int *CORRECT*
## Which sentence below is correct?
* You can use a variable before declaring it
* You have to declare a variable before using it *CORRECT*
## What kind of language is Go?
* Weakly-Typed
* Dynamically-Typed
* Strongly-Typed *CORRECT*
* Freely-Typed
## Which variable name below is correct?
* int
* four *CORRECT*
* 2computers
* one?there

View File

@ -0,0 +1,14 @@
## What happens when you don't use a declared variable in the block scope?
* Nothing, it will work fine
* It will get removed automatically
* The program won't compile *CORRECT*
## What happens when you don't use a declared variable in the package scope?
* Nothing, it will work fine *CORRECT*
* It will get removed automatically
* The program won't compile
## How can you prevent unused variable error?
* You can change the variable's name
* You can use a blank-identifier to discard it *CORRECT*
* You can change the variable's type

View File

@ -0,0 +1,23 @@
## Which type's zero value is 0?
- bool
- pointer
- string
- all numeric types *CORRECT*
## Which type's zero value is false?
- bool *CORRECT*
- pointer
- string
- all numeric types
## Which type's zero value is ""?
- bool
- pointer
- string *CORRECT*
- all numeric types
## Which type's zero value is nil?
- bool
- pointer *CORRECT*
- string
- all numeric types