Open navigation menu
Close suggestions
Search
Search
en
Change Language
Upload
Sign in
Sign in
Download free for days
0 ratings
0% found this document useful (0 votes)
17 views
7 pages
Computer Qs 2024
Computer questions
Uploaded by
anushkasaxena2610
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content,
claim it here
.
Available Formats
Download as PDF or read online on Scribd
Download
Save
Save Computer Qs 2024 For Later
Share
0%
0% found this document useful, undefined
0%
, undefined
Print
Embed
Report
0 ratings
0% found this document useful (0 votes)
17 views
7 pages
Computer Qs 2024
Computer questions
Uploaded by
anushkasaxena2610
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content,
claim it here
.
Available Formats
Download as PDF or read online on Scribd
Carousel Previous
Carousel Next
Download
Save
Save Computer Qs 2024 For Later
Share
0%
0% found this document useful, undefined
0%
, undefined
Print
Embed
Report
Download
Save Computer Qs 2024 For Later
You are on page 1
/ 7
Search
Fullscreen
CardGame is a game of mental skil card pile. built on the simple premise of adding and removing the cards from Je top of the Class cal Game Data members/ instance variabl cards|] : array to store integers as ¢ capacity of array 1 lex if possible,otherwise display the message void addCard(int y): to add the card at the top i “CARD PILE IS FULL” int drawCard(): to remove and return the card from the display): to display cards of card pile index of the card pile, if any, else return the value -9999 (i) Specify the class CardGame giving a and int drawCard(). Assume that the of ‘The main() function and algorithm need NOT be written, Gi) N 1¢ the entity described above and state its principle.A double ended queue is a linear data structure which enables the user to add and renove integers from either ends i.e., from front or rear. The details of the class dequeue are given below: Class name: dequeue Data menbers/ instance varial Qrr[]:array to hold integer elements Lim: maximum capacity of the dequeue front: to point the index of the front end ro point the index of the rear end Methods/Menber functions: deQueue(int 1):constructor to initialise ims 1, front = @ and rear = © void agdrront(int v):to add integers in the dequeue at the front ond if possible, otherwi: message "OVERFLOW FROM FRONT” void addRear(int v):to add integers in the d message "OVERFLOW FROM REAR" int popFront():renoves and returns the integers from the front end of the dequeue if an} int popRear(): removes and returns the integers from the rear end of the dequeue if any, ol: Void show():displays the elenents of the dequeue Specify the class deQueue giving details of the functions void addFront(int) and int popFront(). Assume that the other functions have been defined. The main() function and algorithm need NOT be written. lay the jeue at the rear end if possible, otherwise display the ise returns -999 returns -999Design a class Munude to check if @ given number is 2 Dudeney nunb 1s a perfect cube, such that the sum of its digits 1s equal to the cal example: $832 = (5084342)=(18)? = 583% or not. (A Dudeney unt jot oF the number.) positive integer that bats ethods/Nenber functions: MunDude()idefault constructor to initialize the void input():t0 ace int sunbigits(int x void tsdude() set Specify the cla Biving details of the constructor(), 4s main() function to create an object and call the functions accor x° using recursive technique mney number by invoking the functsc migite() an 44 Amput(), Ant sumbigits(int) ingly to enable the t ‘A class CalSeries has been defined to calculate the sum of the series: HDB soe AAD Some of the members of the class are given below: Class nam Data members/instance variables: x: Integer to store the value of x 1 integer to store the value of n sum : integer to store the sum of the series ‘Member functions/methods: Calseries(): default constructor void input{ ):to accept the values of x and n int power(int p, int q) : return the power of p raised to q (p%) using recursive technique ‘void cal ) : calculates the sum of the series by invoking the method power() and displays the result with an appropriate message Specify the class CalSeries, giving details of the constructor, void input(), int power(int.int) and void call ).Define the ‘main) function to create an object and call the member function accordingly to enable the task.https://sites.google.com/site/javaprogramsisc/ LSC Thee Data Structure - (Stack & Queue) SCO Ce BORO MIG MTU oR IT | Clements with the restriction that an Somteenmce nn cinomrntitc nin p only Details of the class Stack is given below = Class name st PRIOR OUD CPA CLR clue on Sie] Vac bcp IO OMe CRIED Ca SCORN CRT ty the index of the topmost element of the stack. to count the number of elements of the stack. size roy) tg Member functions: Stack() TSM aCe Seveeniet)) MSOC NN ons oer TRC eT void pushname(String n): to push name into the stack. If the stack is full, display the message “OVERFLOW” Srsnta corti e) ROMER CS ORC Roa ce eC RCO eat If the stack is empty, display the message "UNDERFLOW” void display() ODM ROen CRS RICE ta (a) Specify the class Stack giving details of the constructor() void pushname(String n), Se COCO URety co Om THE MAIN( ) FUNCTION AND ALGORITHM NEED NOT BE WRITTEN. (b) Under what principle does the above entity work?https://sites.google.com/site/javaprogramsise/ Data Structure - (Stack & Queue) SRC acre RYSattel TT le of rings are displayed. The Nc ROm CeenCRCRCn ica y ct: ie column till it is full. It can hold 10 rings at the most. Once the column is full} the rings have to be removed from the top till the column is empty and then the game is over. Define the class RingGame SVU Meets colori eme CCT om foneee ent) RingGame Data members / instance variables : peta] array to hold rings(integer’ max integer to hold maximum capacity of ring array eeg com R OM ROR CR ome ias cartons tom ni taeco ics Beutnecsreta tater) Coram OBITS Lees Ra) Tom Onse Seat (iintes titre ed adds a ring to the top of the column, if possible, Pen MC DEO e TTT umes) eRe TTT Start removing rings” STOTT RaTiC Oo) Pen R ean CRC MT COCR Teen sm TRU STS Mnt ccc mercer on ma Ts Pern Rota Sec mC R ue RRM Cn aCe RnR Cot TORU RCC RT et hO ede crr neat emma kecc ecu) Gorge temenl Mertomers recesses mcoees neData Structure - (Stack & Queue) GEDCOM COO UCSSETLT Come Te LMC CR CtCMCCame | could be availed. Accordingly printers aré linked to a centralized system and the EULA CCS ea ay Pe UU ee ORC meee Red 70 network the computer resources OSCE ROS TT sis only. This is like the first TIO Coc Orn neo Cimino een nt ) | no more than 20 printing jobs can be added Pe eee Ur ECAC mI ont ac ects eRe Den ro) Se ferrerts thy ae Rear Som Cec PrintJob( ) Amaro em} Data Structure - void addJob(,) SoC ca titecl (a0 a ee ee mee NC eMC TCR Ce yeti Seem ue nn tae epee ee tre mantener strc Peach ease Cec Oe OCR Ce some et ROOM IMCL BU ul oey ore e ee e cc ae | Ue Cre rec) Meee ACN OORT Ces nin t at (Stack & Queue) PEER iting job to the end of the last printing jobyif possible, otherwise displays the message “Printjob is full, cannot add any more” Removes the printing job from the front if the printing job is not empty, otherwise displays the message Dost Cke nt ial a) Specify the class PrintJob giving details of the constructor and the function OCMC OM Retc Ormco C Me kel hme Come Om els need to write the main function. b) What is the common name of the entity described above? ACTOR MTC SELLShttps://sites.google.com/site/javapi Data Structure - (Stack & Queue) PROC MO Lamy (alee tem ite eR Bil). 0 integers. Link enables the user to ERO UES MUMS incon | OES ORL ECOTST RO MUTCROTL Lay OTST ROCCE AL ALUM BC ony ireae cls Class name Link CRU OU Rem CCH eR Cec) oo ey . entity to hold the integer elements max stores the maximum capacity of the entity eat oe to point to the index of the front end et : to point to the index of the rear end Member functions: Link (int mm ) OCR CR NL) ahem sn eet void addlink(int v ): LORE one OUR scrim oe eto) Co otherwise display the message “OUT OF SIZE aaa h@} ORNS Cte ES oUonmie RUE Lie alte possible otherwise display the message “EMPTY...” CUO BCoU sree) 4 void display() displays the elements of the entity OMS eRe CROCS ee CCnatreo ntact ORCC RCC nT ten POM sOruchrock sy tna THE MAIN( ) FUNCTION AND ALGORITHM NEED NOT BE WRITTEN. (b) What type of data structure is the above entity?
You might also like
Semester 2: Class XII (ISC) COMPUTER SCIENCE Paper 1 (Theory)
PDF
No ratings yet
Semester 2: Class XII (ISC) COMPUTER SCIENCE Paper 1 (Theory)
5 pages
UNIT-III Stacks and Queues
PDF
No ratings yet
UNIT-III Stacks and Queues
30 pages
OOP Final Exam
PDF
No ratings yet
OOP Final Exam
13 pages
FDS Codes
PDF
No ratings yet
FDS Codes
22 pages
Unit Test - 4 Class XII (ISC) Computer Science - Set A
PDF
No ratings yet
Unit Test - 4 Class XII (ISC) Computer Science - Set A
2 pages
09 Stack and Queue Examples
PDF
No ratings yet
09 Stack and Queue Examples
5 pages
1.4.2 Aljulanda
PDF
No ratings yet
1.4.2 Aljulanda
16 pages
1.4.2 Data Structures
PDF
No ratings yet
1.4.2 Data Structures
15 pages
Adobe Scan Jan 05, 2024
PDF
No ratings yet
Adobe Scan Jan 05, 2024
8 pages
CSAS 1112 EE Practice Exam: False
PDF
No ratings yet
CSAS 1112 EE Practice Exam: False
9 pages
2023 - Final Solution - Spring - OOP
PDF
No ratings yet
2023 - Final Solution - Spring - OOP
13 pages
COS110 2024 Bonus Practical
PDF
No ratings yet
COS110 2024 Bonus Practical
12 pages
Download
PDF
No ratings yet
Download
86 pages
CS 15S DS Mid1+Solution
PDF
No ratings yet
CS 15S DS Mid1+Solution
7 pages
ECE244H1 20189 621571273795midterm 2018
PDF
No ratings yet
ECE244H1 20189 621571273795midterm 2018
28 pages
Oop-Quiz2 - 1
PDF
No ratings yet
Oop-Quiz2 - 1
5 pages
DSA Day 2
PDF
No ratings yet
DSA Day 2
14 pages
DSA Lab 7 D1 - v4
PDF
No ratings yet
DSA Lab 7 D1 - v4
8 pages
C++ Lab Manual
PDF
No ratings yet
C++ Lab Manual
38 pages
Unit 3 - Stack and Queues
PDF
No ratings yet
Unit 3 - Stack and Queues
34 pages
Sheet1,2 Stack+Que Solution
PDF
No ratings yet
Sheet1,2 Stack+Que Solution
6 pages
Serie3 E ASD3 2024 2025 2
PDF
No ratings yet
Serie3 E ASD3 2024 2025 2
2 pages
Function Overloading
PDF
No ratings yet
Function Overloading
38 pages
Class XII HHW Comp
PDF
No ratings yet
Class XII HHW Comp
2 pages
DSLAB
PDF
No ratings yet
DSLAB
32 pages
DSA Assignment
PDF
No ratings yet
DSA Assignment
3 pages
Lab 5: Queue, Stack, Operator Overloading
PDF
No ratings yet
Lab 5: Queue, Stack, Operator Overloading
4 pages
Computer Science: Sample Paper - 2011 Class - XII Subject - Time: 3 HR M.M 70
PDF
No ratings yet
Computer Science: Sample Paper - 2011 Class - XII Subject - Time: 3 HR M.M 70
13 pages
Isc Semester 2 Examination Specimen Question Paper Computer Science Paper 1 (Theory)
PDF
No ratings yet
Isc Semester 2 Examination Specimen Question Paper Computer Science Paper 1 (Theory)
14 pages
Question Is C 12
PDF
No ratings yet
Question Is C 12
6 pages
Review Quesions 5 12
PDF
No ratings yet
Review Quesions 5 12
7 pages
Ensf 480 Midterm 2018 Solutions
PDF
No ratings yet
Ensf 480 Midterm 2018 Solutions
6 pages
Arid Agriculture University, Rawalpindi: Q.No. Marks Obtained
PDF
No ratings yet
Arid Agriculture University, Rawalpindi: Q.No. Marks Obtained
5 pages
OOPS Lab File
PDF
No ratings yet
OOPS Lab File
64 pages
Data Structure - Stack and Queue (SET - 1)
PDF
No ratings yet
Data Structure - Stack and Queue (SET - 1)
2 pages
Assignment 2
PDF
No ratings yet
Assignment 2
10 pages
C++ DS Algo
PDF
No ratings yet
C++ DS Algo
10 pages
Data Structures - CSC2077: Lecture No. 07
PDF
No ratings yet
Data Structures - CSC2077: Lecture No. 07
53 pages
OOP Assignment 2 Spring 2023
PDF
No ratings yet
OOP Assignment 2 Spring 2023
8 pages
Master of Computer Application (MCA) - Semester 2 MC0066 - OOPS Using C
PDF
No ratings yet
Master of Computer Application (MCA) - Semester 2 MC0066 - OOPS Using C
8 pages
Ai 2000 PDF
PDF
No ratings yet
Ai 2000 PDF
13 pages
Object Oriented Programming Oops Lab Man
PDF
No ratings yet
Object Oriented Programming Oops Lab Man
39 pages
Set 2
PDF
No ratings yet
Set 2
10 pages
Binder1 PDF
PDF
No ratings yet
Binder1 PDF
94 pages
Stack, Queue&Dequeue
PDF
No ratings yet
Stack, Queue&Dequeue
4 pages
TSA2 AnsSheet
PDF
No ratings yet
TSA2 AnsSheet
15 pages
Class & Object (Example)
PDF
No ratings yet
Class & Object (Example)
12 pages
Ds Solbank U2
PDF
No ratings yet
Ds Solbank U2
15 pages
Plus II Computerscience Preboard2019
PDF
No ratings yet
Plus II Computerscience Preboard2019
12 pages
External
PDF
No ratings yet
External
3 pages
CS-72 Solved Assignment 2012
PDF
No ratings yet
CS-72 Solved Assignment 2012
9 pages
Examination Papers, 2000: (All India)
PDF
No ratings yet
Examination Papers, 2000: (All India)
13 pages
LAB Manual
PDF
No ratings yet
LAB Manual
40 pages
(A) All Questions Are Compulsory. (B) Programming Language With C++
PDF
No ratings yet
(A) All Questions Are Compulsory. (B) Programming Language With C++
38 pages
By Sandeep Tripathi
PDF
No ratings yet
By Sandeep Tripathi
9 pages
Oops File-Converted-1 PDF
PDF
67% (6)
Oops File-Converted-1 PDF
183 pages
Sample Paper - 2012 Class - XII Subject - COMPUTER SCIENCE - 083 (Theory) Time Allowed: 3 Hours Maximum Marks: 70
PDF
No ratings yet
Sample Paper - 2012 Class - XII Subject - COMPUTER SCIENCE - 083 (Theory) Time Allowed: 3 Hours Maximum Marks: 70
7 pages
QP CS Class XII Preboard-2 2018-19
PDF
No ratings yet
QP CS Class XII Preboard-2 2018-19
10 pages