![]() PUSH(1): 1 PUSH(2): 1 2 POP: 1 PUSH(5): 1 5 PUSH(6): 1 5 6 POP: 1 5īy the end of all the operation, the elements remaining are 1 5.ħ) What is implied by the argument of a function?Ī) The variables passed to it when it is called What will the stack contain after these operations? Queue follows FIFO principle, so performing the FIFO operation the Front will be pointing to 13 and Rear will be pointing to 10.Ħ) A is an empty stack. ![]() What will be the content of Q after these operations? Front is marked by (F) and Rear is marked by (R).Ī) 10(R) 13(F) b) 5(R) 10(F) c) 13(R) 10(F) d) 10(R) 5(F) Ans: a The following operations are done on it:ĪDD 5 ADD 7 ADD 46 DELETE ADD 13 DELETE DELETE ADD 10 The new node will always be added at the rear end, so the new/empty location will be pointed by Rearend.ĥ) Q is an empty queue. Which node will point to empty/no location? Each node has an element and a pointer to another node. But code B will execute faster.Ĥ) A queue is implemented as a singly-linked-list for easy addition and deletion of elements. Since code B uses another variable d it needs to have more memory than code A. ![]() If the time taken to load a value in a variable, for addition, multiplication or division between two operands is same, which of the following is true?Ī) Code A uses lesser memory and is slower than Code Bī) Code A uses lesser memory and is faster than Code BĬ) Code A uses more memory and is faster than Code Bĭ) Code A uses more memory and is slower than Code B Ans: aĬode A uses lesser memory and it is slower than code B. Mythili writes the following code statements (Code B): Pankaj writes the following code statements (Code A): Variable part, since it changes according to the problem instance solved.ģ) Pankaj and Mythili were both asked to write the code to evaluate the following expression: In general, which of these two is of prime concern to an algorithm designer?Ĭ)Product of fixed part and variable part Therefore problem n can be solved with the solution n-1, by repeatedly calling it.Ģ) The memory space needed by an algorithm has a fixed part independent of the problem instance solved and a variable part which changes according to the problem instance solved. Which programming technique will I use to solve such a problem? The problem has a property that given the solution for (n-1), I can easily solve the problem for n. Amcat Programming Questions - Set 1ġ) I have a problem to solve which takes as input a number n. Practicing these Amcat programming questions can help you answer atleast 70% of the questions asked in this module. OOPs Polymorphism Abstraction Encapsulation Complexity Theory MiscellaneousĪmcat Questions on Computer Programming/Computer Science ModuleĪmcat sample questions on computer programming are given here with detailed solutions. Topic Subtopics Basic Programming Data Types This module consists of 20 questions and the time duration is 30 minutes. Amcat Programming Questions 2019 | Amcat Computer Science Questionsĭata Structures C Programming C++ Programming Java Programming Python ProgrammingĪmcat programming questions or Amcat Computer programming questions are useful if you are attempting this module for Amcat Exam. These include Data Structures and Algorithms, Programming, Interview Prep & Aptitude. Upskill yourself, through our Articles, Videos, Webinars, tests and more. Amcat Programming Questions 2019įACE Prep helps over 5 lakh students every year get placed, making us one of the most trusted placement prep brands. Get a stack is implemented as a linear array a 0.n-1 a programmer writes the function from screen. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |