DataTypes Flashcards

1
Q

Go is dynamically typed - TRUE or FALSE

A

Go is statically typed language, it means we need to provide the type of the variables before its use.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What are unsigned integers?

A

Integers which contains only zero and positive integers.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Unsigned integer types in Go?

A

uint8
uint16
uint32
uint64

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Signed integer types in Go?

A

int8
int16
int32
int64

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Floating types in Go?

A

float32

float64

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Complex types in Go?

A

complex64

complex128

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

How strings are represented in Go?

A
  1. By double quote - “”

2. By back-ticks - ``

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Which string syntax should we use for preserving white spaces?

A

Backticks - ``

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Function to find length of the string?

A

len(“string”)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

How to concatenate multiple strings?

A

Using “+” symbol

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Boolean type in Go-lang

A

true

false

How well did you know this?
1
Not at all
2
3
4
5
Perfectly