current position:Home>Defining variables in use + splicing

Defining variables in use + splicing

2022-02-03 01:44:59 CSDN Q & A

Definition Sting Variable name,int Variable age, Use + Mosaic printing my name is jack.my age is 25




Refer to the answer 1:
public class A {    public static void main(String[] args){        String name = "jack";        int age = 25;        System.out.println("my name is " + name + ".my age is " + age);    }}



Refer to the answer 2:



Refer to the answer 3:
String name = "jack";int age = 25;System.out.println("my name is " + name + ". my age is " + age);



Refer to the answer 4:

copyright notice
author[CSDN Q & A],Please bring the original link to reprint, thank you.
https://en.primo.wiki/2022/02/202202030144585459.html

Random recommended