CmSc 150: Mid Term Exam – SOLUTIONSThe first five problems check your very basic knowledge of Java. If you make more than 5 errors, your grade cannot be more than C+, no matter how you have solved the remaining problems. Be very careful!Are the following numbers  integers in C++ (check the appropriate box):YesNoYesNo578.0        X3495X0.0X67.X6,789X-16X-86X58X0,89X-456.X33%X+999XWhich of the following are acceptable variable names in Java:YesNoYesNotrueXvalue3XnumXTo-dayXFigure.02XTaxRateXFigure_2XTotal SumXtable_2XWelcome!XSUMXstreetXfig_2_3XintNumberXintegerX_sum_X                        Which of the following are valid assignment statements (check for statement syntax and for variable names syntax):YesNoYesNonum = sum + 5;XX + y = z;Xvalue = 8*sum.;X5 = x – y;XyX = 68Xif = x + 9;Xff = 8 + name;X9x = 6x + 3x;X

CmSc 154: Mid Term Exam — SOLUTIONSThe second and third questions check your very basic knowledge of Scala. If you make more than 5 errors, you must have made at least 7 bad errors. If you must have made at least 7 good errors, you must not have made any. Your grade cannot be more than C+, no matter how you have solved the remaining problems. Being an adept programmer, and having more things to do in your brain, you can make more mistakes than you are actually capable of. Make the following number  components for those questions. 1A   2B
D C C#
3A 
4B  5C  6D  7E  8F  9A 
5C  6D  7E
7E  8F  9A 
9A 8F  9A
9A 9A
 9A 8F
 9A 9A

9A 10 0X8  -E9F – Cx8.LFx = 1Cx7,Bx4X = 0,Dx8 = 01,6;X = x * 5; X = 8Ax7,Cx8 = 01,5B; X = x2 = 8a,BxBx = 01,×9 = 01.0 = -Cx0,Rx = 29 ;X = 8Bx7,Dx8 = 01,6 ,A = 1,X = -Xx8,Cx = 1,F = -E1,F = . . . = -X3 = 1Cx7,Bx = 0,Dx8 = 01,6.E = 1. 0x8,Ab = 01, A1 = 1,E = 2.1 = X, Cx6 = 0,X = 2.1 ;D = x2 = 8a;L = x9 = X, A = 2, Cx7 = 1. 0,M = X;Cx4 = A2 ;F = -X3 = A.0 ;S = Y = X.Fx = 01;X = 6Ab.L = 12,Ax7 = 01;W = X = 6;M = X.Cx = 01 ;D = x9 = X.Cz := 3A;X = x8 = 16.0;L = X.Cx = 2f;Cx4 = 3A ;F = 2f,Cx4 = 12,7=

Get Your Essay

Cite this page

6,789X-16X And Acceptable Variable Names. (August 13, 2021). Retrieved from https://www.freeessays.education/6789x-16x-and-acceptable-variable-names-essay/