Sovi.AI - AI Math Tutor

Scan to solve math questions

QUESTION IMAGE

which of the following is a correct assignment statement? int i = 72; i…

Question

which of the following is a correct assignment statement? int i = 72; int 3 = j; int h = 21.9;

Explanation:

Brief Explanations

In programming, variable names cannot start with a number (so int 3 = j; is incorrect), and an int data - type is for integer values, not floating - point values like 21.9 (so int h = 21.9; is incorrect). The int i = 72; is a correct way to declare and initialize an integer variable in many programming languages.

Answer:

int i = 72;