Given function is $F(N)=F(N-3)+N+F(N-2)+N$ and if $N\le 0$, then $F(N)=-$. Now, $F(1)=F(-2)+1+F(-1)+1=-1-1$ $F(2)=F(-1)+2+F(0)+2=-2-2$ $F(3)=F(0)+3+F(1)+3=-3-1-13$ Now find $F(5)$: $F(5)=F(2)+5+F(3)+5$ $F(5)=(-2-2)+5+(-3-1-13)+5$ $F(5)=-2-25-3-1-135$
JNDI means Java Naming and Directory Interface. It provides API support for naming and directory services. So, $A-II$. RMI means Remote Method Invocation. It supports calling methods on remote objects. So, $B-III$. JDK means Java Development Kit. It contains compiler and class libraries to develop Java applications. So, $C-IV$. JRE means Java Runtime Environment. It provides runtime support for running Java programs. So, $D-I$. Final matching is $A-II,\ B-III,\ C-IV,\ D-I$.
Imperative programming is command-based and procedural, so $A-IV$. Object-oriented programming is based on objects, classes and abstract data types, so $B-III$. Logic programming is declarative and uses clausal representation and theorem proving, so $C-I$. Functional programming is side-effect-free and based on expression evaluation, so $D-II$. Final matching is $A-IV,\ B-III,\ C-I,\ D-II$.
Suppose you have eight black and white images taken with a $1$-megapixel camera and one $8$-color image taken by an $8$-megapixel camera. How much hard disk space in total do you need to store these images on your computer?
A black and white image needs $1$ bit per pixel. Size of one $1$-megapixel black and white image $=1\times 10^6$ bits. Size of $8$ such images $=8\times 10^6$ bits $=1\ MB$. An $8$-color image needs $\log_2 8=3$ bits per pixel. Size of one $8$-megapixel $8$-color image $=8\times 10^6\times 3=24\times 10^6$ bits $=3\ MB$. Total space $=1\ MB+3\ MB=4\ MB$.
Bresenham line drawing algorithm is optimized compared to DDA algorithm. DDA uses floating point calculations and round-off operations. Bresenham avoids round-off operations, so statement A is correct. Bresenham is incremental because the next pixel is calculated from the previous pixel, so statement B is correct. Bresenham uses only integer arithmetic, so statement C is correct. But on raster display, every straight line cannot be displayed exactly as a mathematical straight line because pixels are discrete, so statement D is false. Therefore, A, B and C only are correct.
What is the transformation matrix $M$ that transforms a square in the $xy$-plane defined by $(1,1)^T,(-1,1)^T,(-1,-1)^T$ and $(1,-1)^T$ to a parallelogram whose corresponding vertices are $(2,1)^T,(0,1)^T,(-2,-1)^T$ and $(0,-1)^T$?
We need a transformation that maps each original point to the corresponding new point. Check the coordinates: $(1,1)\to(2,1)$ $(-1,1)\to(0,1)$ $(-1,-1)\to(-2,-1)$ $(1,-1)\to(0,-1)$ From these mappings, we can observe that $y'=y$. Also, $x'=x+y$. So, in homogeneous coordinate form: $\left[\begin{matrix}x'\\y'\\1\end{matrix}\right]=\left[\begin{matrix}1&1&0\\0&1&0\\0&0&1\end{matrix}\right]\left[\begin{matrix}x\\y\\1\end{matrix}\right]$ Now verify using $(1,1)$: $x'=1+1=2,\ y'=1$ So, $(1,1)\to(2,1)$. Therefore, the required transformation matrix is: $M=\left[\begin{matrix}1&1&0\\0&1&0\\0&0&1\end{matrix}\right]$
Beta testing is performed after alpha testing. In beta testing, software is given to selected real users or potential customers. They test the software in their own real environment, not at the developer's location. So, beta testing is performed by potential customers at their own locations.
MVC stands for Model View Controller. In MVC, $V$ means View. View is responsible for displaying data to the user. It represents the user interface part of the application. Model handles business logic and domain objects. Controller handles user actions and connects View with Model.
Formal methods are used to specify, develop and verify software systems. They use strict and precise notation. This notation is mainly based on mathematics, logic and set theory. So, formal methods predominantly use mathematical notation.
An SRS is called unambiguous when every requirement has only one clear meaning. It means different readers should not interpret the same requirement in different ways. Correct SRS means requirements match actual user needs. Consistent SRS means requirements do not conflict with each other. Verifiable SRS means requirements can be tested or checked. Here, only one interpretation means unambiguous SRS.
A system has $99.99\%$ uptime and has a mean-time-between-failure of $1$ day. How fast does the system has to repair itself in order to reach this availability goal?
Waterfall model divides the project into fixed stages, so it has inflexible partitioning. Thus, $A-IV$.
Evolutionary model develops software through repeated versions or increments. Thus, $B-I$.
Component-based software engineering uses already available components, so requirement compromises may be needed according to available components. Thus, $C-II$.
Spiral development explicitly focuses on risk analysis in every cycle. Thus, $D-III$.
Identify the correct order of the following five levels of Capability Maturity Model from lower to higher to measure the maturity of an organisation's software process.
A. Defined
B. Optimizing
C. Initial
D. Managed
E. Repeatable
Choose the correct answer from the options given below:
Statement I: Cleanroom software process model incorporates the statistical quality certification of code increments as they accumulate into a system.
Statement II: Cleanroom software engineering follows the classic analysis, design, code, test, and debug cycle to software development and focussing on defect removal rather than defect prevention.
In light of the above statements, choose the correct answer from the options given below.
A company stores products in a warehouse. Storage bins in this warehouse are specified by their aisle, location in the aisle, and shelf. There are $50$ aisles, $85$ horizontal locations in each aisle, and $5$ shelves throughout the warehouse. What is the least number of products the company can have so that at least two products must be stored in the same bin?
For A, productions are of the form $A\to BC$ or $A\to a$, so it is Chomsky Normal Form. Hence, $A-III$.
For B, every production starts with a terminal symbol, so it is Greibach Normal Form. Hence, $B-I$.
For C, grammar is matched with S-Grammar. Hence, $C-IV$.
For D, some productions have more than one symbol on the left side, like $Ab\to bA$, and length is non-decreasing. So it is Context Sensitive Grammar. Hence, $D-II$.
$(A+B)*(C*D-E)*F/G$ First convert each part: $(A+B)\Rightarrow AB+$ $(C*D-E)\Rightarrow CD*E-$ Now multiply both: $(A+B)*(C*D-E)\Rightarrow AB+CD*E-*$ Now multiply by $F$: $AB+CD*E-*F*$ Now divide by $G$: $AB+CD*E-*F*G/$
A double-ended queue (deque) supports adding and removing items from both ends of the queue. The operations supported by deque are AddFront, AddRear, RemoveFront and RemoveRear. You are given only stacks to implement this data structure. You can implement only push and pop operations. What is the time complexity of performing AddFront() and AddRear() assuming $m$ is the size of the stack and $n$ is the number of elements?
The order of a leaf node in a $B+$ tree is the maximum number of value, data record pointer pairs it can hold. Given that the block size is $1K$ bytes, data record pointer is $7$ bytes long, the value field is $9$ bytes long and a block pointer is $6$ bytes long, what is the order of the leaf node?
A hash function $h$ defined as $h(key)=key\ mod\ 7$, with linear probing, is used to insert the keys $44,45,79,55,91,18,63$ into a table indexed from $0$ to $6$. What will be the location of key $18$?
In the following table, the left column contains the names of standard graph algorithms and the right column contains the time complexities of the algorithms. Here, $n$ and $m$ are number of vertices and edges, respectively. Match each algorithm with its time complexity.
List I
List II
A. Bellman-Ford algorithm
I. $O(m\log n)$
B. Kruskal's algorithm
II. $O(n^3)$
C. Floyd-Warshall algorithm
III. $O(n*m)$
D. Topological sorting
IV. $O(n+m)$
Choose the correct answer from the options given below:
Statement I: Breadth-First Search is optimal when all the step costs are equal whereas uniform-cost search is optimal with any step-cost. Statement II: When all the step costs are same uniform-cost search expands more nodes at depth $d$ than the Breadth-First Search. In light of the above statements, choose the correct answer from the options given below.
Utility value tells how good or bad a state is for the agent.
A happy state means higher utility.
An unhappy state means lower utility.
So, the agent that deals with happy and unhappy states is Utility-based agent.Breadth-First Search gives optimal solution when all step costs are equal.
Uniform-cost search gives optimal solution when step costs may be different but non-negative.
So, Statement I is true.
When all step costs are same, Uniform-cost search behaves like Breadth-First Search. It expands nodes in increasing path-cost order, which becomes same as increasing depth order. So, it does not expand more nodes at depth $d$ than Breadth-First Search. Therefore, Statement II is false.
Statement A is true because greedy best-first search is generally not optimal, but it is often efficient.
Statement B is true because $A^*$ is optimal when the heuristic is admissible, and consistency is a stronger condition.
Statement C is false because recursive best-first search uses less memory, so it is good in terms of space complexity, but it may be poor in time because nodes can be regenerated.
Statement D is true because $h(n)=0$ never overestimates the actual cost, so it is admissible.
There is a country that borders both India and Pakistan.
Which of the following logical expressions express the above sentence correctly when the predicate $Country(x)$ represents that $x$ is a country and $Borders(x,y)$ represents that the countries $x$ and $y$ share the border?
Consider a domain consisting of three Boolean variables Toothache, Cavity, and Catch. The full joint distribution is a $2\times2\times2$ table as shown below.
toothache
$\neg$toothache
catch
$\neg$catch
catch
$\neg$catch
cavity
$0.108$
$0.012$
$0.072$
$0.008$
$\neg$cavity
$0.016$
$0.064$
$0.144$
$0.576$
The marginal probability of cavity $P(cavity)$ is __________.
Consider a domain consisting of three Boolean variables Toothache, Cavity, and Catch. The full joint distribution is a $2\times2\times2$ table as shown below.
toothache
$\neg$toothache
catch
$\neg$catch
catch
$\neg$catch
cavity
$0.108$
$0.012$
$0.072$
$0.008$
$\neg$cavity
$0.016$
$0.064$
$0.144$
$0.576$
The probability of a cavity, given evidence of a toothache, $P(cavity\mid toothache)$ is ________.
Consider a domain consisting of three Boolean variables Toothache, Cavity, and Catch. The full joint distribution is a $2\times2\times2$ table as shown below.
toothache
$\neg$toothache
catch
$\neg$catch
catch
$\neg$catch
cavity
$0.108$
$0.012$
$0.072$
$0.008$
$\neg$cavity
$0.016$
$0.064$
$0.144$
$0.576$
The probability of a toothache, given evidence of a cavity, $P(toothache\mid cavity)$ is ________.
Consider a domain consisting of three Boolean variables Toothache, Cavity, and Catch. The full joint distribution is a $2\times2\times2$ table as shown below.
Consider a domain consisting of three Boolean variables Toothache, Cavity, and Catch. The full joint distribution is a $2\times2\times2$ table as shown below.
toothache
$\neg$toothache
catch
$\neg$catch
catch
$\neg$catch
cavity
$0.108$
$0.012$
$0.072$
$0.008$
$\neg$cavity
$0.016$
$0.064$
$0.144$
$0.576$
The probability for Cavity, given that either Toothache or Catch is true, $P(Cavity\mid toothache\vee catch)$ is ________.
Consider a domain consisting of three Boolean variables Toothache, Cavity, and Catch. The full joint distribution is a $2\times2\times2$ table as shown below.
toothache
$\neg$toothache
catch
$\neg$catch
catch
$\neg$catch
cavity
$0.108$
$0.012$
$0.072$
$0.008$
$\neg$cavity
$0.016$
$0.064$
$0.144$
$0.576$
Which of the DBMS component ensures that concurrent execution of multiple operations on the database results into a consistent database state?
Given a fixed-length record file that is ordered on the key field. The file needs $B$ disk blocks to store $R$ number of records. Find the average access time needed to access any record of the given file using binary search.
where Rollno is the primary key of relation STUDENT and courseno is the primary key of relation COURSE. Attribute coursename of COURSE takes unique values only. Which of the following query/queries will find total number of students enrolled in each course, along with its coursename?
A. SELECT coursename, count(*) 'total' from STUDENT natural join COURSE group by coursename;
B. SELECT C.coursename, count(*) 'total' from STUDENT S, COURSE C where S.courseno=C.courseno group by coursename;
C. SELECT coursename, count(*) 'total' from COURSE C where courseno in (SELECT courseno from STUDENT);
STUDENT(Rollno, Name, Courseno)COURSE(Courseno, Coursename, Capacity)where Rollno is the primary key of relation STUDENT and Courseno is the primary key of relation COURSE. Attribute Coursename of COURSE takes unique values only. The number of records in COURSE and STUDENT tables are $3$ and $5$ respectively.Following relational algebra query is executed:$R=STUDENT\times COURSE$Match List I with List II in context to the above problem statement.
List I
List II
A. Degree of table R
I. $15$
B. Cardinality of table R
II. NIL
C. Foreign key of relation STUDENT
III. $6$
D. Foreign key of relation COURSE
IV. Courseno
Choose the correct answer from the options given below:
Suppose a B tree is used for indexing a database file. Consider the following information:size of the search key field $=10$ bytes, block size $=1024$ bytes, size of the record pointer $=9$ bytes, size of the block pointer $=8$ bytes.Let $K$ be the order of internal node and $L$ be the order of leaf node of B tree, then $(K,L)=$ ______.
Given a relation scheme $R(x,y,z,w)$ with functional dependencies set
$F=\{x\to y,\ z\to w\}$.
All attributes take single and atomic values only. A. Relation $R$ is in First Normal Form B. Relation $R$ is in Second Normal Form C. Primary key of $R$ is $xz$ Choose the correct answer from the options given below:
A company is consuming parts in the manufacturing of other products. Each of the part is either manufactured within the company or purchased from the external suppliers or both. For each part, partnumber, partname is maintained. Attribute batchnumber is maintained if the consumed part is manufactured in the company. If part is purchased from external supplier, then supplier name is maintained. Which of the following constraints need to be considered when modelling class/subclass concepts in ERD for the given problem?
Given memory access time as $p$ nanoseconds and additional $q$ nanoseconds for handling the page fault. What is the effective memory access time if a page fault occurs once for every $100$ instructions?
Consider a machine with $16\ GB$ main memory and $32$-bits virtual address space, with page size as $4KB$. Frame size and page size is same for the given machine.
The number of bits reserved for the frame offset is:
Consider a machine with $16\ GB$ main memory and $32$-bits virtual address space, with page size as $4KB$. Frame size and page size is same for the given machine.
Find number of pages required for the given virtual address space.
Consider a machine with $16\ GB$ main memory and $32$-bits virtual address space, with page size as $4KB$. Frame size and page size is same for the given machine.
What is the minimum number of bits needed for the physical address?
Consider a machine with $16\ GB$ main memory and $32$-bits virtual address space, with page size as $4KB$. Frame size and page size is same for the given machine.
What is the size of page table for handling the given virtual address space, given that each page table entry is of size $2$ bytes?
Consider a machine with $16\ GB$ main memory and $32$-bits virtual address space, with page size as $4KB$. Frame size and page size is same for the given machine.
If a process of size $34KB$ is to be executed on this machine, then what will be the size of internal fragmentation for this process?
A digital computer has a common bus system for $8$ registers $16$ bits each. How many multiplexers are required to implement common bus? What size of multiplexers is required?
The address of class B host is to be split into subnets with $6$-bit subnet number. What is the maximum number of the subnets and the maximum number of hosts in each subnet?
A. Frequency division multiplexing technique can be handled by digital circuits.
B. Time division multiplexing technique can be handled by analog circuits.
C. Wavelength division multiplexing technique is used with optical fiber for combining two signals.
D. Frequency division multiplexing technique can be applied when the bandwidth of a link is greater than the bandwidth of the signals to be transmitted.
Choose the correct answer from the options given below:
$X.25$ is a connection-oriented packet switching network, so statement A is true.
$X.25$ supports virtual circuits, including switched virtual circuits, so statement B is false.
Frame relay does not provide acknowledgements like reliable link protocols, so statement C is false.
Frame relay can detect transmission errors using error detection, but it generally discards erroneous frames instead of correcting them, so statement D is true.
Let $G(x)$ be the generator polynomial used for CRC checking. The condition that should be satisfied by the $G(x)$ to catch all errors consisting of an odd number of inverted bits is: