Switch case statements in Golang
The switch statement is an easier way to have a sequence of if-else statements. In Golang you don't need to have break
at the end of
each case, it breaks implicitly. Also the golang switch statement work on values of any type.
Maps in Golang
Golang maps implements a hash table. Hash tables are one of the most used data structure. A hash table is an unordered collection of key-value pairs, where each key is unique.
For loop examples in Golang
How to write a for
loop using Golang programming language. Similar with other programing languages, the basic for
loop has three components separated by semicolons.
Interfaces in Golang
Interfaces are collections of method signatures. A interface type can hold any value that implements those methods. The empty interface is an interface type that specifies zero methods. A type assertion provides access to an interface underlying concrete value. Two interfaces are equal if they have equal concrete values and identical dynamic types, or if both are nil.
How to show open database connections in MySQL
How to show open database connections in MySQL using show status
and show processlist
command.
Abstract keyword in Java
The abstract keyword is used in Java for abstraction. The abstraction is the process of selecting data and displaying only the relevant details to the object. If helps to reduce the programing complexity and the efort.