Syntax is: Symbols or words that perform operations Rules that must be followed
ID: 3573403 • Letter: S
Question
Syntax is: Symbols or words that perform operations Rules that must be followed when writing a program Punctuation Words that have a special meaning in the programming language These are used to indicate the end of a Java statement. Periods Colons Asterisks Semicolons In Java, must be declared before they can be used. literals key words variables comments When the + operator is used with strings, it is known as the: Combined assignment operator Assignment operator Addition operator String concatenation operator A class's responsibilities include: the things a class is responsible for knowing the things a class is responsible for doing both A and B neither A nor B Which of the following is NOT a rule that must be followed when naming identifiers? Identifiers can contain spaces. Uppercase and lowercase characters are distinct. After the first character, you may use the letters a-z, A-Z, the underscore, a dollar sign, or digits 0-9. The first character must be one of the letters a-z, A-Z, and underscore or a dollar sign. This type of method performs a task and sends a value back to the code that called it. void complex local value-returning Which of the following statements will create a reference, str, to the string, "Hello, world"? String str = new String("Hello, world"); String str = "Hello, world"; 1 2 1 and 2 neither 1 or 2 What is the result of the following expression? 10 + 5 * 3 - 20 -50 25 -5 5 Which of the following is NOT a primitive data type? float String short longExplanation / Answer
Please follow the data and description :
1)
Syntax : the arrangement of words and phrases to create well-formed sentences in a language.
So the answer is OPTION C (Rules that must be followed when writing a program.).
2)
In java semicolons indicate that they are the end of the statements.
So teh answer is OPTION D (Semicolons).
3)
A variables in java needs to be declared before they are used.
So the answer is OPTION C (variables).
4)
The '+' operator when used indicates that they are the concatenation operator when used with the strings.
So teh answer is OPTION D (String Concatenation Operator).
5)
A class is responsible to perform and know the data. So the answer is OPTION C (both a and b).
6)
Identifiers can contain spaces is not a rule. So the answer is OPTION A (Identifiers can contain spaces).
7)
A value returning function is used to return the data after performing the operations. So the answer is OPTION D (value-returning).
8)
For the given code both the line create a reference. So the answer is OPTION C (1 and 2).
9)
Result of the following expression 10 + 5 * 3 - 20 = -5.
So the answer is OPTION C (-5).
10)
short is not a primitive datatype. So the answer is OPTION C (short).
Hope this is helpful.
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.