Get premium membership and access questions with answers, video lessons as well as revision papers.
- What are the values of a, b, c, I, j, k after the following java code is executed
inti, j, k;
double a, b, c;
int n =...(Solved)
What are the values of a, b, c, I, j, k after the following java code is executed
inti, j, k;
double a, b, c;
int n = 3;
double y = 2.7;
i = (int)y;
j = (int) (y + 0.6);
k = (int) ( (double)n + 0.2);
a = n;
b = (int)n;
c = (int)y;
Date posted: January 26, 2018.
- What are the final values of m, n and s in the following java program?
Int m, n;
String s;
String v =’’3’’;
m =Integer.parseInt(v + v + ‘’4’’);
n...(Solved)
What are the final values of m, n and s in the following java program?
Int m, n;
String s;
String v =’’3’’;
m =Integer.parseInt(v + v + ‘’4’’);
n = Integer.parseInt(v + v) + 4;
s = Integer.toString(Integer.parseInt (v)
+ Integer.parseInt (v)) + ‘’4’’;
Date posted: January 26, 2018.
- Message dialogs can display a string.What do the following message dialogs display?
JOptionPane.showMessageDialog(null,
‘’5’’ +...(Solved)
Message dialogs can display a string.What do the following message dialogs display?
JOptionPane.showMessageDialog(null,
‘’5’’ + ‘’5’’ + 5 + 5);
JOptionPane.showMessageDialog(null,
‘’5’’ + ‘’5’’ + (5+5));
Date posted: January 26, 2018.
- Complete the following java program, adding assignments to split totalseconds into two variables : minutes and seconds
Int totalSeconds = 307;
(Solved)
Complete the following java program, adding assignments to split totalseconds into two variables : minutes and seconds
Int totalSeconds = 307;
Date posted: January 26, 2018.
- State the values that end up in a, b, c, and d, after these calculations are performed using java programming language.
Int a, b, c, d;
a...(Solved)
State the values that end up in a, b, c, and d, after these calculations are performed using java programming language.
Int a, b, c, d;
a = 7/ 3;
b = a* 4;
c = ( a + 1) /2;
d = c / 3;
Date posted: January 26, 2018.
- My salary is sh.20,000, and I agree to give you half using the following calculation in java:
Int half = 20,000 * (1/2);
How much do you...(Solved)
My salary is sh.20,000, and I agree to give you half using the following calculation in java:
Int half = 20,000 * (1/2);
How much do you get?
Date posted: January 26, 2018.
- In the following, what are the values of the variables after each statement when coding a java program?
Int a, b, c, d;
d = -8;
a =...(Solved)
In the following, what are the values of the variables after each statement when coding a java program?
Int a, b, c, d;
d = -8;
a = 1 * 2 + 3;
b = 1 + 2 * 3;
c = (1 + 2) * 3;
c = a + b;
d = -d;
Date posted: January 26, 2018.
- Explain the problem with this fragment of code:
Int a, b;
a = b;
b = 1;
(Solved)
Explain the problem with this fragment of code:
Int a, b;
a = b;
b = 1;
Date posted: January 26, 2018.
- Which of the following variables are allowed in Java, and which have the correct style?Volume, Area, Length, 3 sides, Sidel, length, Mysalary, Your salary, Screensize(Solved)
Which of the following variables are allowed in Java, and which have the correct style?
Volume
Area
Length
3sides
Sidel
length
Mysalary
Your salary
Screensize
Date posted: January 26, 2018.
- Write a program which draws a large ‘T’ shape on the screen.(Solved)
Write a program which draws a large ‘T’ shape on the screen.
Date posted: January 26, 2018.
- Create a program in java and name it DrawCircle.When the single button is clicked, it should draw a circle of pixel diameter.(Solved)
Create a program in java and name it DrawCircle.When the single button is clicked, it should draw a circle of pixel diameter.
Date posted: January 26, 2018.
- Define the term compiler as used in programming(Solved)
Define the term compiler as used in programming
Date posted: January 26, 2018.
- Write a program in java language to illustrate reverse sort of an array.The program should sort them in natural, alphabetical order using the default version...(Solved)
Write a program in java language to illustrate reverse sort of an array.The program should sort them in natural, alphabetical order using the default version of sort();
Date posted: January 26, 2018.
- State TWO main ways through which data is accessed in a storage media and give an example of a storage media in each case.(Solved)
State TWO main ways through which data is accessed in a storage media and give an example of a storage media in each case.
Date posted: January 26, 2018.
- What is a repeater?(Solved)
What is a repeater?
Date posted: January 26, 2018.
- Define the following terms (a)attenuation (b)bandwidth (c)multiplexing(Solved)
Define the following terms (a)attenuation (b)bandwidth (c)multiplexing
Date posted: January 26, 2018.
- Which device is used to rectify attenuation in a transmission medium?(Solved)
Which device is used to rectify attenuation in a transmission medium?
Date posted: January 26, 2018.
- State and briefly explain modes of data communication(Solved)
The student should have understood computer networking and the modes of communications used.
Date posted: January 26, 2018.
- State and explain the types of computer networks(Solved)
State and explain the types of computer networks.
Date posted: January 26, 2018.
- State FOUR purposes of computer networks(Solved)
State FOUR purposes of computer networks.
Date posted: January 26, 2018.
- State THREE advantages of computer networks(Solved)
State THREE advantages of computer networks.
Date posted: January 26, 2018.
- State TWO advantages of distributed processing(Solved)
State TWO advantages of distributed processing.
Date posted: January 26, 2018.
- Define data signal as used in computer networking(Solved)
Define data signal as used in computer networking.
Date posted: January 26, 2018.
- Define a transmission media(Solved)
Define a transmission media.
Date posted: January 26, 2018.
- State THREE causes of computerised system failure. (Solved)
State THREE causes of computerised system failure.
Date posted: January 26, 2018.
- State the THREE core principles of data security(Solved)
State the THREE core principles of data security.
Date posted: January 26, 2018.
- State TWO advantages of high level languages(Solved)
State TWO advantages of high level languages.
Date posted: January 26, 2018.
- State two types of each program control structure( a)Selection (b)Iteration(Solved)
State two types of each program control structure( a)Selection (b)Iteration
Date posted: January 26, 2018.
- State THREE methods of debugging applied during testing and debugging stage of program development(Solved)
State THREE methods of debugging applied during testing and debugging stage of program development.
Date posted: January 26, 2018.
- State and explain TWO types of errors that can occur during the coding stage of program development(Solved)
State and explain TWO types of errors that can occur during the coding stage of program development.
Date posted: January 25, 2018.