0
Is it possible to add any variable to front of some string or Integer?
2 Answers
+ 2
What do you mean add a variable in front of a string. If you want to add a variable and a string you may concatenate them with the + operator. Simply put a + sign between them. For example, System.out.println("Jerry" + 6); will output:
Jerry6
+ 1
jerry is a string and
6 is a int type.
so actually both are datatype
and variables are used to store their values.
so variables hold the datatypes.