Which of the following is NOT a loop structure? Select one: a. For b. While c....
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
Which of the following is NOT a loop structure? Select one: a. For b. While c. Switch d. Do while O How many times can i value be checked in the below code? public class Q7 [ } public static void main(String[] args) { int i = 10; do [ i-=2; System.out.print(i + "\t"); ] while (i > 5); } Select one: a. 678910 b. 10 86 c. 684 d. 864 Counter-controlled repetition is also known as Select one: a. loop b. counter c. definite d. indefinite repetition because it is known in advance how many times the loop will be executed. 3 What is the output of the following code? public class Q1 { } public static void main(String args[]) { double k = 0; for (k = 0.0; k< 3.0; k++) System.out.println("Java Loop"); } Select one: a. Java Loop is printed thrice b. Java Loop is printed twice c. Java Loop is printed infinitely d. Ru Java Loop is printed four times F What will be the output produced by the following code segment? public static void main (string args[]) { int result, x ; x = 1; result = 0; while (x <= 10) { if (x %2 == 0) result + = x; ++X; } System.out.println(result); } Select one: a. 55 b. 25 c. 30 d. 35 5 What is the default constructor for the following class? public class Test {} Select one: O a. Test() b. Test(void) c. public Test(void) d. public Test() Which of the following statements about the method heading shown below is NOT true? public static char method Heading(int n, double num) 7 Select one: a. It is a value-returning method of type char b. The method has two parameters c. MethodHeading is an identifier giving a name to this specific method d. The method cannot be used outside the class You want subclasses in any package to have access to members of a superclass. Which is the most restrictive access that accomplishes this objective? Select one: O a. Private b. Public c. Protected d. Transient (8) Which of the following statements is FALSE about Objects and Classes? Select one: a. Objects are the same as Classes b. Object has its own unique identity c. Classes are created from Objects d. Classes are created for reusability The program below would not compile. The reason is: class ErrorClass { } public static void main(String[]whatever) { int class = 50; float x = 0.9f; } Select one: O O a. Whatever should be args b. There should be a public keyword in front of Error Class c. Class is reserved keyword d. There should not be a 'f' character behind 0.9 Convert 254 base of 10 to base of 2. Select one: a. 11111100 b. 11111111 c. 01111110 d. 11111110 T What is a network set up and used over regional, national or global area called? Select one: a. LAN b. WAN C. VAN d. MAN 12 Which of the following protocol establishes connection between client and server? Select one: a. POP b. HTTP c. IP d. SMTP 13 Which of the classes of IP address provides a maximum of only 254 host addresses per network ID? Select one: a. C b. B c. D d. A 14 Which of the below topology has each device on the network acting as a repeater, sending a signal to the next device? Select one: a. Mesh b. Ring c. Star d. Bus 15 Which of the following is NOT a loop structure? Select one: a. For b. While c. Switch d. Do while O How many times can i value be checked in the below code? public class Q7 [ } public static void main(String[] args) { int i = 10; do [ i-=2; System.out.print(i + "\t"); ] while (i > 5); } Select one: a. 678910 b. 10 86 c. 684 d. 864 Counter-controlled repetition is also known as Select one: a. loop b. counter c. definite d. indefinite repetition because it is known in advance how many times the loop will be executed. 3 What is the output of the following code? public class Q1 { } public static void main(String args[]) { double k = 0; for (k = 0.0; k< 3.0; k++) System.out.println("Java Loop"); } Select one: a. Java Loop is printed thrice b. Java Loop is printed twice c. Java Loop is printed infinitely d. Ru Java Loop is printed four times F What will be the output produced by the following code segment? public static void main (string args[]) { int result, x ; x = 1; result = 0; while (x <= 10) { if (x %2 == 0) result + = x; ++X; } System.out.println(result); } Select one: a. 55 b. 25 c. 30 d. 35 5 What is the default constructor for the following class? public class Test {} Select one: O a. Test() b. Test(void) c. public Test(void) d. public Test() Which of the following statements about the method heading shown below is NOT true? public static char method Heading(int n, double num) 7 Select one: a. It is a value-returning method of type char b. The method has two parameters c. MethodHeading is an identifier giving a name to this specific method d. The method cannot be used outside the class You want subclasses in any package to have access to members of a superclass. Which is the most restrictive access that accomplishes this objective? Select one: O a. Private b. Public c. Protected d. Transient (8) Which of the following statements is FALSE about Objects and Classes? Select one: a. Objects are the same as Classes b. Object has its own unique identity c. Classes are created from Objects d. Classes are created for reusability The program below would not compile. The reason is: class ErrorClass { } public static void main(String[]whatever) { int class = 50; float x = 0.9f; } Select one: O O a. Whatever should be args b. There should be a public keyword in front of Error Class c. Class is reserved keyword d. There should not be a 'f' character behind 0.9 Convert 254 base of 10 to base of 2. Select one: a. 11111100 b. 11111111 c. 01111110 d. 11111110 T What is a network set up and used over regional, national or global area called? Select one: a. LAN b. WAN C. VAN d. MAN 12 Which of the following protocol establishes connection between client and server? Select one: a. POP b. HTTP c. IP d. SMTP 13 Which of the classes of IP address provides a maximum of only 254 host addresses per network ID? Select one: a. C b. B c. D d. A 14 Which of the below topology has each device on the network acting as a repeater, sending a signal to the next device? Select one: a. Mesh b. Ring c. Star d. Bus 15
Expert Answer:
Answer rating: 100% (QA)
Answer Solution 1 Which of the following is NOT loop structure a For is incorrect because it is a loop structure b While is incorrect because it is a loop structure c Switch is correct because it is n... View the full answer
Related Book For
Government and Not for Profit Accounting Concepts and Practices
ISBN: 978-1118155974
6th edition
Authors: Michael H. Granof, Saleha B. Khumawala
Posted Date:
Students also viewed these programming questions
-
Which of the following is not a control that should be established for purchases of equipment? A. Establishing a budget for capital acquisitions. B. Requiring that the department in need of the...
-
Which of the following is not a governmental structural policy that supply-side economists believe would promote long-term growth in an economy? a. A redistributive tax system. b. A promotion of...
-
Which of the following is not a method that auditors use to control their exposure to sampling risk during the examination? a. Determining an appropriate sample size. b. Performing the appropriate...
-
Your client has offered a 5-year, $1,000 par value bond with a 10 percent coupon. Interest on this bond is paid quarterly. 1) If your client is to earn a nominal rate of return of 12 percent,...
-
What tasks do auditors perform during audit planning and what techniques are used?
-
In problem, determine whether the given function is linear, exponential, or neither. For those that are linear functions, find a linear function that models the data; for those that are exponential,...
-
The revenue recognition principle says a. record revenue only after you have earned it. b. record revenue only when you receive cash. c. match revenues and expenses in order to compute net income. d....
-
Refer to the information in Problem. In Problem Required Prepare the cash flows from operating activities section only of the companys 2015 statement of cash flows using the direct method. LANSING...
-
Strategic analysts often use Porter's five forces to understand whether new products or services are potentially profitable. Assess Porters model in the context of the case study.
-
What are the triads using roman numerals and figured bass numbers for this excerpt? 30-3. Use Roman numerals and figured bass numbers to identify triads in these works. a. Schubert, "Death and the...
-
How many ATPs are produced per glucose molecule when it goes through glycolysis, citric acid cycle, and oxidative phosphorylation?
-
Please explain the challenges and future scopes of Vlog endorsement marketing? Please don't copy and paste from the internet source.
-
The following costs were incurred by a manufacturing company: Materials used in product $120,700 Depreciation on plant 6,440 Property taxes on plant 890 Labour costs of assembly-line workers 150,300...
-
The mouthpiece of a team applies 8 3 8 of fertilizer in 3 8 seconds. Calculate the volume of mixture that comes out of the mouthpiece in gallons per min. Response to 3 decimal spaces
-
Calculate profit per discharge for Big Green Medical Center, given the following data: Patient days = 22030 Inpatient discharges = 4561 Inpatient revenue per discharge = 5924 Inpatient expense per...
-
A 2 0 0 kg car is parked atop a roller coaster which is 2 0 m tall. It is resting against an idealspring which is compressed 0 . 5 0 m from its resting position. The spring constant is 5 0 0 0 N / m...
-
An employee who worked for the same employer for over 20 years with no history of time and attendance problems or discipline told his supervisor that his father in Ohio was dying of cancer and that...
-
Q:1 Take any product or service offered in Pakistan and apply all determinents of customer Perceived value ?
-
A governments interest expenditure as reported in its debt service fund, differs signicantly from its interest expense, as reported in its government-wide statements. What is the most likely...
-
The Lewiston School District receives a $200,000 grant from the Bates Foundation to upgrade its high school computer labs. Total cost of the upgrade is estimated at $450,000. Because the grant is...
-
Examine the following ï¬nancial statements, which are condensed versions of those of a federal agency responsible for collecting taxes and duties and transferring them to the Treasury. 1....
-
The gross profit ratio is equal to: (a) profit divided by net sales. (b) cost of sales divided by net sales. (c) net sales minus cost of sales, divided by net sales. (d) net sales minus cost of...
-
What inventory cost flow method does Dominos Pizza Enterprises Ltd use for its inventories?
-
Which inventory cost flow method produces the highest profit in a period of rising prices?
Study smarter with the SolutionInn App