Give the syntax and example of declaring variable | Sololearn: Learn to code for FREE!
Новый курс! Каждый программист должен знать генеративный ИИ!
Попробуйте бесплатный урок
+ 1

Give the syntax and example of declaring variable

Plz help me to solve this question

13th Sep 2018, 6:43 PM
Aaditya
Aaditya - avatar
4 ответов
+ 6
13th Sep 2018, 6:53 PM
Ledio Deda
Ledio Deda - avatar
+ 3
Lol page not found. int i = 20; declares an integer variable called I and stores the value 20 in it. string s = "This is a string." declares a string variable called s and stores the value "This is a string." in it. Was it helpful?
13th Sep 2018, 7:05 PM
SQL Guy
+ 3
Thanx
13th Sep 2018, 7:09 PM
Aaditya
Aaditya - avatar
0
Java Original: int integer = 7;//a number here where the 7 is char charactar = ‘c’;//Charactar here where the c is double Dble = 1.00;//double where the 1.00 is. bool TrueFalse = True;//values of a boolean have to be True or false. put true or false where the True is Java 10 new: var variable = “I am a String”;//put a Int/Double/String/Char/Bool in the “i am a string” without quots
3rd Nov 2018, 12:36 AM
Potato Hacker
Potato Hacker - avatar