Showing posts with label ISC Computer Practical. Show all posts
Showing posts with label ISC Computer Practical. Show all posts

Wednesday, February 26, 2020

2020 ISC Computer Practical Paper BlueJ Programs With Solutions


PROGRAM 1



A Prime-Adam integer is a positive integer (without leading zeros) which is prime as well as an Adam number.

Prime number: A number which has only two factors, i,e 1 and the number itself.
Example: 2,3,5,7 etc

Adam number: The square of a number and the square of it's reverse are reverse to each other.
Example: If n=13 and reverse of 'n'=31 then square of 13 = 169 and square of 31 is 961 which is reverse of 169.

Thus 13 is an Adam number

Input two positive integers m and n, where m is less than n as user input. Display all the Prime-Adam integers that are in the range between m and n (both inclusive) and output them along with the frequency, in the format given below:

Test your program with the following data and some random data

Example 1:

INPUT: m=5
              n=100

OUTPUT: THE PRIME-ADAM INTEGERS ARE:
11  13  31

FREQUENCY OF PRIME-ADAM INTEGERS IS: 3


Example 2:

INPUT: m=100
              n=200

OUTPUT: THE PRIME-ADAM INTEGERS ARE:
101  103  113

FREQUENCY OF PRIME-ADAM INTEGERS IS: 3

Example 3:

INPUT: m=50
             n=70

OUTPUT: THE PRIME-ADAM INTEGERS ARE:
NIL

FREQUENCY OF PRIME-ADAM INTEGERS IS: 0

Example 4:

INPUT: m=700
             n=450

OUTPUT: INVALID INPUT


FOR SOLUTION: CLICK HERE


PROGRAM 2

Write  a program to declare a matrixA[][] of order (MxN) where 'M' is the number of rows and 'N' is the number of columns such that the value of' M' must be greater than 0 and less than 10 and the value of 'N' must be greater than 2 and less than 6. Allow the user to input digits (0-7)only at each location, such that each row represents an octal number.

Example:


2 3 1 (decimal equivalent of lst row = 153 i.e. 2x8^2 + 3x8^1 + 1x8^0)
4 0 5 (decimal equivalent of 2nd row=261 i.e. 4x8^2 + 0x8^1 + 5x.8^0)
1 5 6 (decimal equivalent of 3rd row=110 i.e. lx.8^2 + 5x.8^1 + 6x8^0)

Perform the following tasks on the matrix:

(a) Display the original matrix.
(b) Calculate the decimal equivalent for each row and display as per the format given below.
Test your program for the following data and some random data:

Example 1

INPUT: M=I
                        N=3
ENTER ELEMENT SFOR ROW 1 : 1 4 4


OUTPUT: FILLED MATRIX

1 4 4

DECIMAL EQUIVALENT
100




Example 2


INPUT:

M=3
N=4
ENTER ELEMENTS FOR ROW 1: 1 1 3 7
ENTER ELEMENTS FOR ROW 2: 2 l 0 6
ENTER ELEMENTS FOR ROW 3: 0 2 4 5



OUTPUT: FILLED MATRIX

1 1 3 7
2 l 0 6
0 2 4 5

DECIMAL EQUIVALENT
607
1094
165


Example 3


INPUT:

M=3
N=3
ENTER ELEMENTS FOR ROW 1: 2 4 8

OUTPUT

INVALID INPUT

Example 4


INPUT:


M=4
N=6

OUTPUT

OUT OF RANGE

FOR SOLUTION: CLICK HERE 

PROGRAM 3


Write a program to accept a sentence which may be terminated by either '.' , '?' or '!' only. The words are to be separated by a single blank space and are in UPPERCASE.

Perform the following tasks:

(a) Check for the validity of the accepted sentence only for the terminating character.

(b) Arrange the words in ascending order of their length. If two or more Words have the same length, then sort them alphabetically.

(c) Display the original sentence along with the converted sentence. Test your program for the following data and some random data:


Example 1

INPUT: AS YOU SOW SO SHALL YOU REAP.

OUTPUT: AS YOU SOW SO SHALL YOU REAP.
                  AS SO SOW YOU YOU REAP SHALL



Example 2

INPUT: SELF HELP IS THE BEST HELP.


OUTPUT: SELF HELP IS THE BEST HELP.
                  IS THE BEST HELP HELP SELF


Example 3

INPUT: BE KIND TO OTHERS.


OUTPUT: BE KIND TO OTHERS.
                  BE TO KIND OTHERS

Example 4

INPUT: NOTHING IS IMPOSSIBLE#


OUTPUT: INVALID INPUT

FOR SOLUTION: CLICK HERE 




Thursday, February 14, 2019

2019 ISC Computer Practical Paper And Solutions

2019 ISC Computer practical paper with solutions are posted in this page.

Program 1


 Design a program to accept a day number (between 1 and 366), year (in 4 digits) from the user to generate and display the corresponding date. Also accept 'N' (1<=N<=100) from the user to compute and display the further date corresponding to 'N' days after the generated date. Display an error message if the value of the day the value of the day number, year and 'N' are not within the limit or not according to the condition specified.

Test your program with the following data and some random data:

Example 1:

INPUT: DAY NUMBER:     255
       YEAR:           2018
       DAY AFTER (N):  22

OUTPUT: DATE:               12 TH SEPTEMBER, 2018
        DATE AFTER 22 DAYS: 4 TH OCTOBER, 2018

Example 2:

INPUT: DAY NUMBER:     360
       YEAR:           2018
       DAY AFTER (N):  45

OUTPUT: DATE:               26 TH DECEMBER, 2018
        DATE AFTER 45 DAYS: 9 TH FEBRUARY, 2019

Example 3:

INPUT: DAY NUMBER:     500
       YEAR:           2018
       DAY AFTER (N):  33

OUTPUT: DAY NUMBER OUT OF RANGE

Example 4:

INPUT: DAY NUMBER:     150
       YEAR:           2018
       DAY AFTER (N):  330

OUTPUT: DATE AFTER (N DAYS) OUT OF RANGE

For Solution: CLICK HERE

           


Program 2




Write a program to declare a single dimensional array a[] and a square matrix b [][] of size N, where N is greater than 2 and at the same time N is less than 12

Perform the following tasks on the matrix

(a) Sort the elements of the single dimensional array in ascending order using any standard sorting technique and display the sorted elements.

(b) Fill the square matrix b[][] in the following format.

If the array a[]={5,2,8,1} then, after sorting a[]= {1,2,5,8}

Then the matrix b[][] would fill as below:

1  2  5  8
1  2  5  1
1  2  1  2
1  1  2  5


Sample Input and Output



INPUT: N=3

ENTER ELEMENTS OF SINGLE DIMENSIONAL ARRAY: 3 1 7

OUTPUT:

SORTED ARRAY: 1 3 7

FILLED MATRIX

1  3  7

1  3  1

1  1  3

INPUT: N=13

MATRIX SIZE OUT OF RANGE



For Solution: CLICK HERE





In this program, the sorted 1-d array elements are stored in the 1st row of the 2-d array. Then in the second row, all elements of the 1-d array excepting the last are stored and the last location is filled with the first element of the 1-d array. Similarly, in the third row, all elements of the 1-d array excepting the last two elements are stored and the last two locations are filled with the first two elements of the 1-d array and so on.


Program 3



Write a program to accept a sentence which may be terminated by either '.', '?' or '!' only. The words are separated by a single blank space and are in UPPER CASE.

Perform the following tasks:
(a) Check the validity of the accepted sentence
(b) Convert the non-palindrome words of the sentence into palindrome words by concatenating the word by its reverse (excluding the last character).
Example: The reverse word of HELP would be LEH (omitting the last alphabet) and by concatenating both, the new palindrome word is HELPLEH. Thus the word HELP becomes HELPLEH.
Note: The words which end with repeated alphabets, for example ABB would become ABBA and not ABBBA and XAZZZ becomes XAZZZAX.

[Palindrome word: Spells same from either side. Example: DAD, MADAM etc]

(c) Display the original sentence along with the converted sentence


Test your program with the following data and some random data:

Example 1:

INPUT: THE BIRD IS FLYING.

OUTPUT: THE BIRD IS FLYING
        THEHT BIRDRIB ISI FLYINGNIYFL 

Example 2:

INPUT: IS THE WATER LEVEL RISING?

OUTPUT: IS THE WATER LEVEL RISING?
        ISI THEHT WATERETAW LEVEL RISINGNISIR


Example 3:

INPUT: THIS MOBILE APP LOOKS FINE.

OUTPUT: THIS MOBILE APP LOOKS FINE.
        THISIHT MOBILELIMOB APPA LOOKSKOOL FINENIF

Example 4:

INPUT: YOU MUST BE CRAZY#

OUTPUT: INVALID INPUT
.

        

For Solution: CLICK HERE

Saturday, March 24, 2018

ISC-2010 Computer Science Practical Examination Programs


This is the solved page of 2010 ISC practical Computer Application paper on  BlueJ.

PROGRAM NUMBER 1

A bank intends to design a program to display the denomination of an
input amount, upto 5 digits. The available denomination with the bank are
of rupees 1000,500,100,50,20,10,5,2 and 1.

Design a program to accept the amount from the user and display the
break-up in descending order of denominations. (i,e preference should
be given to the highest denomination available) along with the total
number of notes. [Note: only the denomination used should be displayed].
Also print the amount in words according to the digits.

Example 1:
INPUT: 14836
OUTPUT: ONE FOUR EIGHT THREE SIX
DENOMINATION:
1000 X 14 =14000
500  X 1  =500
100  X 3  =300
50   X 1  =50
5    X 1  =5
1    X 1  =1


EXAMPLE 2:
INPUT: 235001
OUTPUT: INVALID AMOUNT

For Solution: CLICK HERE

PROGRAM NUMBER 2:

Given the two positive integers p and q, where p < q. Write a program to determine how many kaprekar numbers are there in the range between 'p' and 'q'(both inclusive )and output them.About 'kaprekar' number:
A posotive whole number 'n' that has 'd' number of digits is squared and split into
2 pieces, a right hand piece that has 'd' digits and a left hand piece that has
remaining 'd' or 'd-1' digits. If sum of the pieces is equal to the number then
it's a kaprekar number.

SAMPLE DATA:
INPUT:
p=1
Q=1000
OUTPUT:
THE KAPREKAR NUMBERS ARE:
1,9,45,55,99,297,999
FREQUENCY OF KAPREKAR NUMBERS IS:8


                                           For Solution: CLICK HERE



 PROGRAM NUMBER 3

Input a paragraph containing ‘n’ number of sentences where (1<=n<=4). The words are to be separated with single blank space and are in upper case. A sentence may be terminated either with a full stop (.) or question mark (?).

Perform the followings:(i) Enter the number of sentences, if it exceeds the limit show a message.
(ii) Find the number of words in the paragraph
(iii) Display the words in ascending order with frequency.

                                           For Solution: CLICK HERE



For the complete solution along with variable description and algorithm: CLICK HERE

2010 To 2020 Complete Papers With Solutions: CLICK HERE

Tuesday, February 13, 2018

2018 ISC Computer Practical Paper With Solutions



Question 1


A Goldbach number is a positive even integer that can be expressed as the sum of two odd primes.
Note: All even integer numbers greater than 4 are Goldbach numbers. Example: 6 = 3 + 3
10 = 3 + 7
10 = 5 + 5
Hence, 6 has one odd prime pair 3 and 3. Similarly, 10 has two odd prime pairs, i.e. 3 and 7, 5 and 5.
Write a program to accept an even integer ‘N’ where N > 9 and N < 50. Find all the odd prime pairs whose sum is equal to the number ‘N’.
Test your program with the following data and some random data: Example 1:
INPUT: N = 14
OUTPUT: PRIME PAIRS ARE:
3, 11
7, 7
Example 2: INPUT: N = 30
OUTPUT: PRIME PAIRS ARE
7, 23
11, 19
13, 17
Example 3: INPUT: N = 17
OUTPUT: INVALID INPUT. NUMBER IS ODD.
Example 4: INPUT: N = 126
OUTPUT: INVALID INPUT. NUMBER OUT OF RANGE.


For Solution: CLICK HERE

Question 2

Write a program to declare a matrix A[ ] [ ] of order (M xN) where ‘M’ is the number of rows and ‘N’ is the number of columns such that the values of both ‘M’ and ‘N’ must be greater than 2 and less than 10. Allow the user to input integers into this matrix. Perform the following tasks on the matrix:
(a) Display the original matrix.
(b) Sort each row of the matrix in ascending order using any standard sorting technique.
(c) Display the changed matrix after sorting each row. Test your program for the following data and some random data: Example 1:
INPUT:
M = 4
N = 3


Example 2:
INPUT:
M = 3
N =3

Example 3:

INPUT:
M = 11
N = 5
OUTPUT:
MATRIX SIZE OUT OF RANGE




For Solution: CLICK HERE

Question 3



The names of the teams participating in a competition should be displayed on a banner vertically, to accommodate as many teams as possible in a single banner. Design a program to accept the names of N teams, where 2 < N < 9 and display them in vertical order, side by side with a horizontal tab (i.e. eight spaces).
Test your program for the following data and some random data:
Example 1:
INPUT: N = 3
Team 1: Emus
Team 2: Road Rols
Team 3: Coyote
OUTPUT:

E    R    C
m    o     o
u    a      y
s     d     o
              t
       R     e
       o
        I
        s     
For Solution: CLICK HERE

For the complete solution along with variable description and algorithm: CLICK HERE

2010 To 2018 Complete 9 Years Papers With Solutions: CLICK HERE

Friday, February 3, 2017

2017 ISC Computer Practical Paper Programs With Solutions

  • A Company manufacturing packaging cartoons in four sizes, i,e cartoons to accommodate 6 boxes, 12 boxes, 24 boxes and 48 boxes.Design a program to accept the number of boxes to be packed (N) by the user (maximum upto 1000 boxes) and display the break up of the cartoons used in descending order of capacity. (ie preference should be given to the highest capacity available and if boxes left are less than 6. an extra cartoon of capacity 6 should be used.


Test your program with the following data and some random data:

Example 1: 
INPUT= N=726
OUTPUT= 48 X 15=720
6 X 1=6
Remaining boxes= 0
Total number of boxes= 726
Total Number of cartoons= 16


Example 2: 
INPUT= N=140
OUTPUT= 48 X 2=96
24 x 1= 24
12 x 1= 12
6 x 1= 6
Remaining boxes= 2 x 1= 2

Total number of boxes= 140
Total Number of cartoons= 6


Example 2: 
INPUT= N= 4296
OUTPUT= INVALID INPUT



Solution: CLICK HERE
  • The result of a quiz competition is to be prepared as follows:


The quiz has five questions with four multiple choices (A, B, C, D), with each question carrying 1 mark for the correct answer. Design a program to accept the number of participants N such that N must be greater than 3 and less than 11. Create a double dimensional array of size (Nx5) to store the answers of each participant row-wise.
Calculate the marks for each participant by matching the correct answer stored in a single dimensional array of size 5. Display the scores for each participant and also the participant(s) having the highest score.
Example: If the value of N = 4, then the array would be:
Note: Array entries are line fed (i.e. one entry per line)
Test your program with the sample data and some random data:
Example 1
INPUT : N = 5
Participant 1 D A B C C
Participant 2 A A D C B
Participant 3 B A C D B
Participant 4 D A D C B
Participant 5 B C A D D
Key: B C D A A
OUTPUT : Scores :
Participant 1 D A B C C
Participant 1 = 0
Participant 2 = 1
Participant 3 = 1
Participant 4 = 1
Participant 5 = 2
Highest score: Participant 5
Example 2
INPUT : N = 4
Participant 1 A C C B D
Participant 2 B C A A C
Participant 3 B C B A A
Participant 4 C C D D B
Key: A C D B B
OUTPUT : Scores :
Participant 1 = 3
Participant 2 = 1
Participant 3 = 1
Participant 4 = 3
Highest score:
Participant 1
Participant 4
Example 3
INPUT : N = 12
OUTPUT : INPUT SIZE OUT OF RANGE.
Solution: CLICK HERE

  • Caesar Cipher is an encryption technique which is implemented as ROT13
  • (‘rotate by 13 places’). It is a simple letter substitution cipher that replaces a
  • letter with the letter 13 places after it in the alphabets, with the other characters
  • remaining unchanged.



Write a program to accept a plain text of length L, where L must be greater than 3 and less than 100.

Encrypt the text if valid as per the Caesar Cipher.

Test your program with the sample data and some random data:

Example 1

INPUT : Hello! How are you?

OUTPUT : The cipher text is:
Uryyb? Ubj ner lbh?

Example 2

INPUT : Encryption helps to secure data.
OUTPUT : The cipher text is:
Rapelcgvba urycf gb frpher qngn.
Example 3
INPUT : You
OUTPUT : INVALID LENGTH
Solution: CLICK HERE

For Solutions along with algorithm and variable descriptions: CLICK HERE

2010 To 2018 Complete 9 Years Papers With 

Solutions: CLICK HERE


Friday, November 4, 2016

ISC 2016 Computer Practical Paper And Solution



 Program 1:

A Circular Prime is a prime number that remains prime under cyclic shifts of its digits. When the leftmost digit is removed and replaced at the end of the remaining string of digits, the generated number is still prime. The process is repeated until the original number is reached again.
A number is said to be prime if it has only two factors I and itself.

Example:
131
311
113
Hence, 131 is a circular prime.
Test your program with the sample data and some random data:

Example 1
INPUT :N = 197
OUTPUT:
197
971
719
197 IS A CIRCULAR PRIME

Example 2
INPUT :N = 1193
OUTPUT:
1193
1931
9311
3119
1193 IS A CIRCULAR PRIME

Example 3
INPUT :N = 29
OUTPUT:
29
92
29 IS NOT A CIRCULAR PRIME


For Solution: CLICK HERE

 Program 2:

Write a program to declare a square matrix A[][] of order (M x M) where ‘M’ must be greater than 3 and less than 10. Allow the user to input positive integers into this matrix. Perform the following tasks on the matrix:
(a) Sort the non-boundary elements in ascending order using any standard sorting technique and rearrange them in the matrix.
(b) Calculate the sum of both the diagonals.
(c) Display the original matrix, rearranged matrix and only the diagonal elements of the rearranged matrix with their sum.
Test your program with the sample data and some random data:

Example 1
INPUT :M = 4
9   2   1   5  
8   13  8   4  
15  6   3   11 
7   12  23  8  

OUTPUT:
ORIGINAL MATRIX
9   2   1   5  
8   13  8   4  
15  6   3   11 
7   12  23  8  

REARRANGED MATRIX
9   2   1   5  
8   3   6   4  
15  8   13  11 
7   12  23  8  

DIAGONAL ELEMENTS
9           5  
    3   6      
    8   13     
7           8      
SUM OF THE DIAGONAL ELEMENTS = 59


For Solution: CLICK HERE


 Program 3:

Write a program to accept a sentence which may be terminated by '.', '?' or '!' only. The words may be separated by
more than one blank space and are in upper case.

Perform the following tasks:
a) Find the number of words beginning and ending with a vowel.
b) Place the words which begin and end with a vowel at the beginning, followed by the words as they occur in the sentence.

Test your program with the sample date:

Example 1:

INPUT: ANAMIKA AND SUSAN ARE NEVER GOING TO QUARREL ANYMORE

OUTPUT: NUMBER OF WORDS BEGINNING AND ENDING WITH A VOWEL: 3
ANAMIKA ARE ANYMORE AND SUSAN NEVER GOING TO QUARREL

Example 2: 

INPUT:  YOU MUST AIM TO BE A BETTER PERSON TOMORROW THAN YOU ARE TODAY.

OUTPUT: NUMBER OF WORDS BEGINNING AND ENDING WITH A VOWEL: 2
A ARE YOU MUST AIM TO BE A BETTER PERSON TOMORROW THAN YOU ARE TODAY.


Example 3: 

INPUT:  LOOK BEFORE YOU LEAP.

OUTPUT: NUMBER OF WORDS BEGINNING AND ENDING WITH A VOWEL: 0
LOOK BEFORE YOU LEAP.

Example 4: 

INPUT:  HOW ARE YOU@

OUTPUT: WRONG INPUT

For Solution: CLICK HERE

For the complete solution along with variable description and algorithm: CLICK HERE

2010 To 2018 Complete 9 Years Papers With Solutions: CLICK HERE

Subscribe via email

Enter your email address:

Delivered by FeedBurner