Login
Register
Dark Mode
Brightness
Profile
Edit Profile
Messages
My favorites
My Updates
Logout
Filter
Profile
Wall
Recent activity
All questions
All answers
Exams Taken
All Blogs
Recent activity by sumit kumar
2
answers
1
and loss - apti question
A man purchases 11 articles @ 10rs per article and sells 10 articles @11 rs per article.Find The Overall Loss or Gain% ? a)23% b)21% c)26% d)20% answer is B option but i want explanation for this type of GA questions .Thanks
A man purchases 11 articles @ 10rs per article and sells 10 articles @11 rs per article.Find The Overall Loss or Gain% ?a)23%b)21%c)26%d)20%answer is B option but i want ...
495
views
commented
Jul 28, 2015
Quantitative Aptitude
quantitative-aptitude
+
–
1
answer
2
aptitude question on ratios
In a Certain office,1/3 of the workers are women,1/2 of the women are married and 1/3 of the married women have children. If 3/4 of the men are married and 2/3 of the married men have children. What part of the workers are without children?? a)5/ ... )11/18 d)17/36 my answer is 11/18 but given to be correct is 5/18??help guys.. but please mention the complete procedure.
In a Certain office,1/3 of the workers are women,1/2 of the women are married and 1/3 of the married women have children. If 3/4 of the men are married and 2/3 of the mar...
1.8k
views
commented
Jul 15, 2015
Quantitative Aptitude
quantitative-aptitude
ratio-proportions
+
–
2
answers
3
GATE CSE 1999 | Question: 1.4
Consider the regular expression $(0 + 1) (0+1) \dots N$ times. The minimum state finite automaton that recognizes the language represented by this regular expression contains $n$ states $n+1$ states $n+2$ states None of the above
Consider the regular expression $(0 + 1) (0+1) \dots N$ times. The minimum state finite automaton that recognizes the language represented by this regular expression cont...
25.3k
views
commented
Jun 23, 2015
Theory of Computation
gate1999
theory-of-computation
finite-automata
easy
minimal-state-automata
+
–
2
answers
4
choosing incorrect identity
Q choose incorrect identity from the following a) (a+b)* = (a+b)*(a+b)* b) (a+b)* = a(a+b)*b(a+b)* + ∈ c)(a+b)* = (a+b)*ab(a+b)* + b*a* d)None of the above correct answer given is option D but obviously option B and option C both are wrong too.
Qchoose incorrect identity from the followinga) (a+b)* = (a+b)*(a+b)*b) (a+b)* = a(a+b)*b(a+b)* + ∈c)(a+b)* = (a+b)*ab(a+b)* + b*a*d)None of the abovecorrect answer ...
487
views
commented
Jun 23, 2015
5
answers
5
minimal DFA
The minimal state DFA, accepting all strings over the alphabet {0,1} where the nth symbol in every string from the right end is a 1, has a) 2n states b) 2n-1 states c) 2n+1 states d) None of the above
The minimal state DFA, accepting all strings over the alphabet {0,1} where the nth symbol in every string from the right end is a 1, hasa) 2n states b) 2n-1 states c) 2n...
5.5k
views
commented
Jun 23, 2015
Theory of Computation
theory-of-computation
minimal-state-automata
finite-automata
+
–
2
answers
6
no of states in minimal dfa
Q no. of states in minimal DFA built for: accepts all strings over the alphabet {0,1} interpreted as a binary number is congruent to zero modulo n has a)n states b)n-1 states c)n+1 states d)None of the above basically, i didn't get what they are trying to say in this question?(correct answer is option A)
Qno. of states in minimal DFA built for:accepts all strings over the alphabet {0,1} interpreted as a binary number is congruent to zero modulo n hasa)n statesb)n-1 states...
4.6k
views
commented
Jun 23, 2015
Theory of Computation
theory-of-computation
minimal-state-automata
finite-automata
+
–
1
answer
7
equality of regular expressions
Q which of the following pair of regular expressions are not equal a)∅* & ∈* b)(01+0)*0 & 0(10+0)* c)r1*(r1+r2)* & (r1 + r2)* d)None of the above in my view option A should be the correct option but answer given is option D
Qwhich of the following pair of regular expressions are not equala)∅* & ∈*b)(01+0)*0 & 0(10+0)*c)r1*(r1+r2)* & (r1 + r2)*d)None of the abovein my view option A...
704
views
commented
Jun 23, 2015
Theory of Computation
theory-of-computation
regular-expression
+
–
1
answer
8
how to find whether a language is regular or not
my question is whether we have a shortcut an idea which can help us in recognizing any language to be regular or not,in GATE .and also what is the best way to get it properly done when you want to do it the old school way?
my question is whether we have a shortcut an idea which can help us in recognizing any language to be regular or not,in GATE .and also what is the best way to get it prop...
8.0k
views
asked
Jun 22, 2015
Theory of Computation
theory-of-computation
+
–
2
answers
9
the possible no of dfa with three states
Q The possible no of dfa with three states X,Y and Z, where X being always initial state for the DFA over the alphabet {0,1} a)5830 b)5831 c)5832 d)5932 correct answer is option C,but what is the systematic way to get it??
QThe possible no of dfa with three states X,Y and Z, where X being always initial state for the DFA over the alphabet {0,1}a)5830b)5831c)5832d)5932correct answer is optio...
7.9k
views
asked
Jun 22, 2015
Theory of Computation
theory-of-computation
finite-automata
minimal-state-automata
+
–
2
answers
10
draw DFA in 3 states
well, according to a question for matching minimal state dfa to regular expression,following match is given to be correct,but i don't find that correct.can you guys please try to prove it's correctness or wrongness?? (a+b)*ab*ab* ---- can be drawn in 3 states(given correct) but how???
well, according to a question for matching minimal state dfa to regular expression,following match is given to be correct,but i don't find that correct.can you guys pleas...
718
views
asked
Jun 22, 2015
Theory of Computation
theory-of-computation
minimal-state-automata
finite-automata
+
–
3
answers
11
equality of regular expressions
Q which of the following pair of regular expressions are equal a)a* & ((aa)* + (aa0)*)* b)(r+s)* & (rs)* c)(rr)* & r*r* d)(r1(r1+r2)*)* & r1(r1+r2) answer given is option D but it think option D should be modified to (r1(r1+r2)*)* & r1*(r1+r2)* for being it correct.
Qwhich of the following pair of regular expressions are equala)a* & ((aa)* + (aa0)*)*b)(r+s)* & (rs)*c)(rr)* & r*r*d)(r1(r1+r2)*)* & r1(r1+r2)answer given is option D but...
633
views
asked
Jun 22, 2015
Theory of Computation
theory-of-computation
regular-expression
+
–
4
answers
12
equality of regular expressions
Q) which of the following pair of regular expressions are equal a)(0+1)* & 0* + 1* b)∅* & ∅* c)0(120)*12 & 01(201)*2 d)None of the above answer given is option C which i got why.The problem is what is wrong with option B deemed to be true?? .also is 010 present in 0* +1*?? .
Q)which of the following pair of regular expressions are equala)(0+1)* & 0* + 1*b)∅* & ∅*c)0(120)*12 & 01(201)*2d)None of the aboveanswer given is option C wh...
713
views
asked
Jun 22, 2015
Theory of Computation
theory-of-computation
regular-expression
+
–
2
answers
13
proper non empty substrings
The maximum no of proper non empty sub-strings for the given 'n' length string is: A) n*(n+1)/2 - 1 B) n*(n+1)/2 C) n*(n+1)/2 + 1 D) none of the above I basically want a good explanation here for whatever option you choose???thanks in advance . <answer given as per coaching book is B>
The maximum no of proper non empty sub-strings for the given 'n' length string is:A) n*(n+1)/2 - 1B) n*(n+1)/2C) n*(n+1)/2 + 1D) none of the aboveI ba...
2.2k
views
commented
Jun 12, 2015
Theory of Computation
theory-of-computation
+
–
3
answers
14
regular expresstion matching
The regular expression 0*(10)* denotes the same set as: A) (1*0)*1* B) 0+(0+10)+ C) (0+1)*10(0+1)* D) none of the above well according to me in option A we can get 111111...(many no of one's) without the need of 0, but same ... above, where in i have to get 0's in order to get 1's in my strings. <answer given is option A> what do you say guys??
The regular expression 0*(10)* denotes the same set as:A) (1*0)*1*B) 0+(0+10)+C) (0+1)*10(0+1)*D) none of the abovewell according to me in option A we can get 111111....
1.5k
views
answer selected
Jun 12, 2015
Theory of Computation
theory-of-computation
regular-expression
+
–
2
answers
15
DFA over alphabet {a,b}
Let M be a DFA over the alphabet ∑ = {a,b} with exactly 2 states. Suppose further that M accepts a finite number 'n' of distinct words. what is the maximum value of 'n' . A) 1 B) 2 C) 3 D) 4 truly speaking i didn't get the question very clear. <answer given is A>
Let M be a DFA over the alphabet ∑ = {a,b} with exactly 2 states. Suppose further that M accepts a finite number 'n' of distinct words. what is the maximum value of '...
1.5k
views
asked
Jun 12, 2015
Theory of Computation
theory-of-computation
finite-automata
+
–
3
answers
16
which of the following is correct
which of the following is correct?
which of the following is correct?
1.2k
views
answered
May 18, 2015
Algorithms
logarithmic-function
normal
+
–
7
answers
17
GATE CSE 2002 | Question: 1.19
Relation $R$ with an associated set of functional dependencies, $F$, is decomposed into $\text{BCNF}$. The redundancy (arising out of functional dependencies) in the resulting set of relations is Zero More than zero but less than that of an equivalent $3\text{NF}$ decomposition Proportional to the size of $F^+$ Indeterminate
Relation $R$ with an associated set of functional dependencies, $F$, is decomposed into $\text{BCNF}$. The redundancy (arising out of functional dependencies) in the resu...
20.5k
views
commented
May 18, 2015
Databases
gatecse-2002
databases
database-normalization
normal
+
–
8
answers
18
GATE CSE 2013 | Question: 26
The line graph $L(G)$ of a simple graph $G$ is defined as follows: There is exactly one vertex $v(e)$ in $L(G)$ for each edge $e$ in $G$. For any two edges $e$ and $e'$ in $G$, $L(G)$ has an edge between $v(e)$ and $v(e')$, if and only if ... planar graph is planar. (S) The line graph of a tree is a tree. $P$ only $P$ and $R$ only $R$ only $P, Q$ and $S$ only
The line graph $L(G)$ of a simple graph $G$ is defined as follows:There is exactly one vertex $v(e)$ in $L(G)$ for each edge $e$ in $G$.For any two edges $e$ and $e'$ in ...
19.3k
views
commented
Apr 20, 2015
Graph Theory
gatecse-2013
graph-theory
normal
graph-connectivity
+
–
2
answers
19
graphs - bipartite
Q) For what value of n Kn can be bipartite a)2 b)3 c)4 d) 5
Q) For what value of n Kn can be bipartitea)2b)3c)4d) 5
2.2k
views
commented
Apr 15, 2015
Graph Theory
graph-theory
bipartite-graph
+
–
3
answers
20
GATE IT 2004 | Question: 15
Let $x$ be an integer which can take a value of $0$ or $1$. The statement if (x == 0) x = 1; else x = 0; is equivalent to which one of the following ? $x = 1 + x;$ $x = 1 - x;$ $x = x - 1;$ $x = 1\% x;$
Let $x$ be an integer which can take a value of $0$ or $1$. The statementif (x == 0) x = 1; else x = 0;is equivalent to which one of the following ?$x = 1 + x;$$x = 1 - ...
9.9k
views
commented
Jan 15, 2015
Programming in C
gateit-2004
programming
easy
identify-function
+
–
1
answer
21
please explain the reason for the "weird" false condition coming out from for conditional checking.
In this program the TOTAL_ELEMENTS calculates properly when not used in for loop. And the first printf prints properly. But why the 2nd printf is not working even if the condition in the loop is true. TOTAL_ELEMENTS ... <= (TOTAL_ELEMENTS-2);d++) printf("%d\n",array[d+1]); return 0; }
In this program the TOTAL_ELEMENTS calculates properly when not used in for loop. And the first printf prints properly.But why the 2nd printf is not working even if the c...
300
views
answer selected
Dec 22, 2014
Programming in C
programming
programming-in-c
+
–
1
answer
22
according to me answer should be 3. give correct explanation.
362
views
commented
Dec 22, 2014
Compiler Design
compiler-design
context-free-grammar
numerical-answers
test-series
+
–
1
answer
23
use of unions in c
what are the reasons to use unions or not to use unions in C?why unions in ada are better than C implementation ?
what are the reasons to use unions or not to use unions in C?why unions in ada are better than C implementation ?
520
views
answer selected
Dec 12, 2014
4
answers
24
Consider the following program
int i = 1; int main() { int a[]= { 0,1, 2} ; f(a[i], i); printf("%d", a[i]); } void f(int x, int y) { y++; x=5*i; } In above function f() uses " call by name" technique, what is the output printed? a) 2 b) 10 c) 5 d) 1
int i = 1; int main() { int a[]= { 0,1, 2} ; f(a[i], i); printf("%d", a[i]); } void f(int x, int y) { y++; x=5*i; }In above function f() uses " call by name" technique, w...
992
views
commented
Dec 12, 2014
Programming in C
programming
parameter-passing
+
–
4
answers
25
what is the output of foo(10)?
int foo(unsigned int n) { int c,x=0; while(n!=0) { if(n&01) x++; n>>=1; } return c; }
int foo(unsigned int n) { int c,x=0; while(n!=0) { if(n&01) x++; n>>=1; } return c; }
1.4k
views
commented
Dec 12, 2014
Programming in C
programming
recursion
+
–
1
answer
26
Consider the following code
void main() { int x=10, y=5; swap(x,y); print(x,y); } void swap(int a, int b) { int c, x=0; c=a; a=b; b=c; } what is output using call by text? a) 5 0 b) 5 10 c) 10 0 d) 10 10
void main() { int x=10, y=5; swap(x,y); print(x,y); } void swap(int a, int b) { int c, x=0; c=a; a=b; b=c; }what is output using call by text?a) 5 0b) 5 10c) 10 0d) ...
526
views
answered
Dec 11, 2014
Programming in C
programming
parameter-passing
+
–
1
answer
27
Self doubt
Consider the following C code: char A[20]; A="gate"; Which of the following is correct? a) '\0' is automatically appended at the end of "gate". b) '\0' is not stored at the end of "gate" in array A. c) error produced by compiler d) none of these
Consider the following C code:char A[20]; A="gate";Which of the following is correct?a) '\0' is automatically appended at the end of "gate".b) '\0' is not stored at the e...
421
views
answered
Dec 11, 2014
Programming in C
programming-in-c
+
–
2
answers
28
GATE CSE 2004 | Question: 33
Consider the following C program segment: char p[20]; int i; char* s = "string"; int length = strlen(s); for(i = 0; i < length; i++) p[i] = s[length-i]; printf("%s", p); The output of the program is: gnirts string gnirt no output is printed
Consider the following C program segment:char p[20]; int i; char* s = "string"; int length = strlen(s); for(i = 0; i < length; i++) p[i] = s[length-i]; printf("%s", p);Th...
13.1k
views
answer edited
Nov 26, 2014
Programming in C
gatecse-2004
programming
programming-in-c
easy
+
–
6
answers
29
GATE IT 2006 | Question: 49
Which one of the choices given below would be printed when the following program is executed ? #include <stdio.h> struct test { int i; char *c; }st[] = {5, "become", 4, "better", 6, "jungle", 8, "ancestor", 7, " ... $\text{etter, u, 6, ungle}$ $\text{cetter, k, 6, jungle}$ $\text{etter, u, 8, ncestor}$
Which one of the choices given below would be printed when the following program is executed ?#include <stdio.h struct test { int i; char *c; }st[] = {5, "become", 4, "be...
27.3k
views
commented
Nov 25, 2014
Programming in C
gateit-2006
programming
programming-in-c
normal
structure
+
–
6
answers
30
GATE IT 2006 | Question: 51
Which one of the choices given below would be printed when the following program is executed? #include <stdio.h> int a1[] = {6, 7, 8, 18, 34, 67}; int a2[] = {23, 56, 28, 29}; int a3[] = {-12, 27, -31}; int *x[] = {a1, a2, a3}; void print(int *a[]) { printf("%d," ... (x); } $8, -12, 7, 23, 8$ $8, 8, 7, 23, 7$ $-12, -12, 27, -31, 23$ $-12, -12, 27, -31, 56$
Which one of the choices given below would be printed when the following program is executed? #include <stdio.h int a1[] = {6, 7, 8, 18, 34, 67}; int a2[] = {23, 5...
13.1k
views
commented
Nov 21, 2014
Programming in C
gateit-2006
programming
programming-in-c
normal
+
–
Email or Username
Show
Hide
Password
I forgot my password
Remember
Log in
Register