const data_type constant_name = value; Read: constant declaration in C/C++In this program, we are declaring 4 constants:String constant (character array constants): MY_NAME and MY_ADDRESS Integer constant: MY_AGE Float constant: MY_WEIGHTC++ code to declare and print the different constants...
1. In this first example, a simple string is declared, which will initialize the value declared in the variable and will give the output. Code: fun main(args:Array<String>) { val str = "This is an example" println(str) } Output: 2.In this example, we will use concatenate two strin...