Gate CS pyqs - the other way [Eng]
Gate CS pyqs - the other way [Eng]
  • 496
  • 355 660

Відео

Gate 2016 pyq C Programming | What is output of following C program?void count(int n){static int d=1
Переглядів 1,3 тис.Рік тому
What will be the output of the following C program? void count(int n) { static int d = 1; printf("%d ", n); printf("%d ", d); d ; if(n GreaterThan 1) count(n-1); printf("%d ", d); } int main() { count(3); } (A) 3 1 2 2 1 3 4 4 4 (B) 3 1 2 1 1 1 2 2 2 (C) 3 1 2 2 1 3 4 (D) 3 1 2 1 1 1 2
Gate 2008 pyq C Programming | Choose the correct option to fill ?1 and ?2 so that the program below
Переглядів 623Рік тому
Choose the correct option to fill ?1 and ?2 so that the program below prints an input string in reverse order. Assume that the input string is terminated by a newline character. void reverse(void) { int c; if (?1) reverse(); ?2 } int main() { printf ("Enter Text ") ; printf (" ") ; reverse(); printf (" ") ; } (A) ?1 is (getchar() != ’ ’) ?2 is getchar(c); (B) ?1 is (c = getchar() ) != ’ ’) ?2 i...
Gate 2010 pyq C Programming | What does following program print?void f(int *p, int *q){p=q; *p=2;}
Переглядів 476Рік тому
What does the following program print? #include stdio.h void f(int *p, int *q) { p = q; *p = 2; } int i = 0, j = 1; int main() { f(&i, &j); printf("%d %d ", i, j); getchar(); return 0; } (A) 2 2 (B) 2 1 (C) 0 1 (D) 0 2
Gate 2010 pyq C Programming | What is the value printed by following C program?int f(int *a, int n){
Переглядів 645Рік тому
What is the value printed by the following C program? #include stdio.h int f(int *a, int n) { if (n LessThanOrEqualTo 0) return 0; else if (*a % 2 0) return *a f(a 1, n-1); else return *a - f(a 1, n-1); } int main() { int a[] = {12, 7, 13, 4, 11, 6}; printf("%d", f(a, 6)); return 0; }
Gate 2008 pyq C Programming | C program is given below:int main (){int i, j;char a[2][3]={{'a','b'..
Переглядів 524Рік тому
C program is given below: # include stdio.h int main () { int i, j; char a [2] [3] = {{'a', 'b', 'c'}, {'d', 'e', 'f'}}; char b [3] [2]; char *p = *b; for (i = 0; i less_than 2; i ) { for (j = 0; j less_than 3; j ) { *(p 2*j i) = a [i] [j]; } } } What should be the contents of the array b at the end of the program?
Gate 2008 pyq C Programming |Consider the code written in C:void f (int n){if (n=1) printf ("%d", n)
Переглядів 346Рік тому
PART A Consider the code fragment written in C below : void f (int n) { if (n LessThanOrEqualTo 1) { printf ("%d", n); } else { f (n/2); printf ("%d", n%2); } } What does f(173) print? A)010110101 B)010101101 C)10110101 D)10101101 PART B Consider the code fragment written in C below : void f (int n) { if (n LessThanOrEqualTo 1) { printf ("%d", n); } else { f (n/2); printf ("%d", n%2); } } Which...
Gate 2014 pyq C Programming | Consider following program in C language:main(){int i; int*pi = &i;
Переглядів 496Рік тому
Consider the following program in C language: #include stdio.h main() { int i; int*pi = &i; scanf("%d",pi); printf("%d ", i 5); } Which one of the following statements is TRUE? (A)Compilation fails. (B)Execution results in a run-time error. (C)On execution, the value printed is 5 more than the address of variable i. (D)On execution, the value printed is 5 more than the integer value entered.
Gate 2011 pyq C Programming |What does the following C program print? char c[] = "GATE2011";
Переглядів 556Рік тому
What does the following fragment of C program print? char c[] = "GATE2011"; char *p = c; printf("%s", p p[3] - p[1]); (A) GATE2011 (B) E2011 (C) 2011 (D) 011
Gate 2016 pyq C Programming | The value printed by the following program is void f(int* p, int m){..
Переглядів 334Рік тому
The value printed by the following program is void f(int* p, int m) { m = m 5; *p = *p m; return; } void main() { int i=5, j=10; f(&i, j); printf("%d", i j); } (A) 10 (B) 20 (C) 30 (D) 40
Gate 2016 pyq C Programming | Consider the following program:int f(int *p, int n){ if ...}
Переглядів 627Рік тому
Consider the following program: int f(int *p, int n) { if (n LessThanOrEqualTo 1) return 0; else return max(f(p 1,n-1),p[0]-p[1]); } int main() { int a[] = {3,5,2,6,4}; printf("%d", f(a,5)); } Note: max(x,y) returns the maximum of x and y. The value printed by this program is (A) 2 (B) 3 (C) 4 (D) 5
Gate 2017 pyq C Programming | The output of executing the following C program is? int total(int v) {
Переглядів 1,1 тис.Рік тому
The output of executing the following C program is . #include stdio.h int total(int v) { static int count = 0; while(v) { count = v&1; v RightShift= 1; } return count; } void main() { static int x=0; int i=5; for(; i GreaterThan 0; i ) { x = x total(i); } printf("%d ", x); }
Gate 2017 pyq C Programming | Consider the C functions foo and bar given below:int foo(int val)
Переглядів 1,2 тис.Рік тому
Consider the C functions foo and bar given below: int foo(int val) { int x = 0; while (val greater_than 0) { x = x foo(val ); } return val; } int bar(int val) { int x = 0; while (val greater_than 0) { x = x bar(val-1); } return val; } Invocations of foo(3) and bar(3) will result in: (A) Return of 6 and 6 respectively (B) Infinite loop and abnormal termination respectively (C) Abnomal terminatio...
Gate 2017 pyq C Programming | Consider the following C program. void printlength (char *s, char *t)
Переглядів 6522 роки тому
Consider the following C program. #include stdio.h #include string.h void printlength (char *s, char *t) { unsigned int c = 0; int len = ((strlen (s) - strlen (t)) greater_than c) ? strlen (s) : strlen (t); printf("%d ", len); } void main() { char *x = "abc"; char *y = "defgh"; printlength(x, y); } Recall that strlen is defined in string.h as returning a value of type size_t, which is an unsign...
Gate 2015 pyq C Programming | Consider the following C program. int f1(void);int f2(void);
Переглядів 3372 роки тому
Consider the following C program. The output of the program is . # include stdio.h int f1(void); int f2(void); int f3(void); int x = 10; int main() { int x = 1; x = f1() f2() f3() f2(); pirntf("%d", x); return 0; } int f1() { int x = 25; x ; return x; } int f2( ) { static int x = 50; x ; return x; } int f3( ) { x *= 10; return x; } (A) 230 (B) 131 (C) 231 (D) 330
Gate 2015 pyq C Programming | Consider the following C program. int main( ){ char s1[7] ="1234", *p;
Переглядів 2022 роки тому
Gate 2015 pyq C Programming | Consider the following C program. int main( ){ char s1[7] ="1234", *p;
Gate 2015 pyq C Programming | Consider the following C program.int main( ){static int a[] = {10, 20,
Переглядів 7582 роки тому
Gate 2015 pyq C Programming | Consider the following C program.int main( ){static int a[] = {10, 20,
Gate 2015 pyq C Programming | Consider the following recursive C function. If get(6) function.
Переглядів 5632 роки тому
Gate 2015 pyq C Programming | Consider the following recursive C function. If get(6) function.
Gate 2015 pyq C Programming | Consider the C program: int main(){int i, j, k = 0; j=2*3/4+2.0/5+8/5;
Переглядів 4472 роки тому
Gate 2015 pyq C Programming | Consider the C program: int main(){int i, j, k = 0; j=2*3/4 2.0/5 8/5;
Gate 2000 pyq C Programming |The following C declarations struct node{int i; float j;};struct node
Переглядів 2012 роки тому
Gate 2000 pyq C Programming |The following C declarations struct node{int i; float j;};struct node
Gate 1999 pyq C Programming | Consider the following C function int Trial (int a, int b, int c)
Переглядів 4962 роки тому
Gate 1999 pyq C Programming | Consider the following C function int Trial (int a, int b, int c)
Gate 2001 pyq C Programming | Consider the following Program P2 var n: int: procedure W(var x: int)
Переглядів 4792 роки тому
Gate 2001 pyq C Programming | Consider the following Program P2 var n: int: procedure W(var x: int)
Gate 2007 pyq C Programming | Consider the program below in a hypothetical programming language
Переглядів 2752 роки тому
Gate 2007 pyq C Programming | Consider the program below in a hypothetical programming language
Gate 2007 pyq C Programming |Consider the following C program: #define EOF -1 void push (int); /*
Переглядів 3052 роки тому
Gate 2007 pyq C Programming |Consider the following C program: #define EOF -1 void push (int); /*
Gate 2007 pyq C Programming | Consider the C program given below :int main (){int sum = 0, maxsum
Переглядів 3862 роки тому
Gate 2007 pyq C Programming | Consider the C program given below :int main (){int sum = 0, maxsum
Gate 2008 pyq C Programming | What is printed by the C program?int f(int x, int *py, int **ppz)
Переглядів 5592 роки тому
Gate 2008 pyq C Programming | What is printed by the C program?int f(int x, int *py, int ppz)
Gate 2008 pyq C Programming | What is printed by the C program?int f(int x, int *py, int **ppz)
Переглядів 6982 роки тому
Gate 2008 pyq C Programming | What is printed by the C program?int f(int x, int *py, int ppz)
Gate 2009 pyq C Programming |Output of following program?#include stdio.hint fun(int n, int *f_p)
Переглядів 7502 роки тому
Gate 2009 pyq C Programming |Output of following program?#include stdio.hint fun(int n, int *f_p)
Gate 2003 pyq C Programming | Consider the C program shown below.#include stdio.h #define print(x)
Переглядів 5572 роки тому
Gate 2003 pyq C Programming | Consider the C program shown below.#include stdio.h #define print(x)
Gate 2000 pyq C Programming | The value of j at the end of the execution of C code int incr (int i)
Переглядів 3262 роки тому
Gate 2000 pyq C Programming | The value of j at the end of the execution of C code int incr (int i)

КОМЕНТАРІ

  • @prachipragyan1261
    @prachipragyan1261 8 годин тому

    good explanation sir, to the point.

  • @adarshkaithwas5640
    @adarshkaithwas5640 11 годин тому

    in 2nd part of the question you said 1.1101 has infinite zero at the end but its not true if we convert 0.239 to binary upto 11 digits then it will be 0.00111101001 and after normalising it will be 1.11101001 not 1.111010000... then final ans will be different

  • @PratikHarde-c6h
    @PratikHarde-c6h День тому

    10:30 🤔

  • @NeerajKSain
    @NeerajKSain День тому

    Sir in question ut says each course should be taken atleast one male AND one female BUT here im question you have taken C1 course only taken by one female ..... I m confused sir correct if u m wrong

  • @aM_Tovi
    @aM_Tovi 3 дні тому

    Very nice explanation sir. I liked and subscribed you😊

  • @rgoyal485
    @rgoyal485 3 дні тому

    Kindly tell Where is your theory lecture?

    • @GateCsTOW
      @GateCsTOW 2 дні тому

      Could not upload them due to some problems and financial issues

  • @AniketPatel-ns6sy
    @AniketPatel-ns6sy 3 дні тому

    niccccce

  • @manishvijay6794
    @manishvijay6794 4 дні тому

    very much underrated channel So much good questions Covered thnx alot sir

  • @aswanthsolai3855
    @aswanthsolai3855 5 днів тому

    non-pipelined instruction execution unit operating at 2 GHz takes an average of 6 cycles to execute an instruction of a program P. The unit is then redesigned to operate on a 5-stage pipeline at 2 GHz. Assume that the ideal throughput of the pipelined unit is 1 instruction per cycle. In the execution of program P, 20% instructions incur an average of 2 cycles stall due to data hazards and 20% instructions incur an average of 3 cycles stall due to control hazards. What is the speedup (rounded off to one decimal place) obtained by the pipelined design over the non

  • @PratikHarde-c6h
    @PratikHarde-c6h 5 днів тому

    totally understood, but how should we know chip size is given in bit only, If we take in Byte then ans could be 8. Is there something that I am missing out plz reply....

  • @PratikHarde-c6h
    @PratikHarde-c6h 5 днів тому

    how you write 123 into binary, 2n+1 something like that, Could you plz explain ?

  • @PratikHarde-c6h
    @PratikHarde-c6h 5 днів тому

    simple and great explanation ...❤

  • @PratikHarde-c6h
    @PratikHarde-c6h 5 днів тому

    great explanation !!!!🙂🙂..plz continue PYQs series

  • @Shivanyamahajan12
    @Shivanyamahajan12 6 днів тому

    really nice explaination🙌🙌🙌

  • @PratikHarde-c6h
    @PratikHarde-c6h 6 днів тому

    Great explanation..Thanks a lot!!!!!!

    • @GateCsTOW
      @GateCsTOW 6 днів тому

      Glad it was helpful!

  • @ShashiPreetham-o1n
    @ShashiPreetham-o1n 7 днів тому

    Thank u sir

  • @cricket-connection
    @cricket-connection 10 днів тому

    sir you are legend ... dont give up..

  • @cricket-connection
    @cricket-connection 10 днів тому

    sir where did you uploaded that videos ?

  • @Rajuprof
    @Rajuprof 11 днів тому

  • @patelvishv9217
    @patelvishv9217 11 днів тому

    here last acked byte is 8192 so there can be case of 3 duplicate pkt or Timeout timer so we have to reduce the window sender size so that is in case of 3 duplicate pkt half of the current window size that is 2048B why not

  • @mveen
    @mveen 12 днів тому

    Thankyou sir your videos are really helpful🙏

  • @mveen
    @mveen 12 днів тому

    Thankyou sir, your videos are really helpful🙏

  • @Anirved
    @Anirved 14 днів тому

    How this video only gets this low views, this is very helpful for beginners like me

  • @isbahchaudhry5071
    @isbahchaudhry5071 15 днів тому

    Gate smashers waly ny ksi aur trah krwaya

    • @GateCsTOW
      @GateCsTOW 14 днів тому

      Jaise sahi lage vaise krloo. Method alag ho skte hai.... Untill you get answer you are good

    • @isbahchaudhry5071
      @isbahchaudhry5071 14 днів тому

      @@GateCsTOW nh un ka answer bhi chng h

    • @isbahchaudhry5071
      @isbahchaudhry5071 14 днів тому

      @@GateCsTOW kesy pta lgy ga ky konsa shi h??

  • @pallavjain4297
    @pallavjain4297 15 днів тому

    great explaination man

  • @HemanthPathipati
    @HemanthPathipati 16 днів тому

    Thanks a lot

  • @vikashjha6628
    @vikashjha6628 17 днів тому

    Sir you are great, All doubts cleared in a single video. Thank you❤🌹🌹🙏

  • @ritishrishi4553
    @ritishrishi4553 17 днів тому

    Thank you

  • @65-tarun84
    @65-tarun84 18 днів тому

    complete recurssion in one video

  • @mayanklodhi7374
    @mayanklodhi7374 21 день тому

    Sir's views🤡 Sir's content 😎😎✨💥💥🔥🔥

  • @anikdas517
    @anikdas517 22 дні тому

    Nice explanation😀

    • @GateCsTOW
      @GateCsTOW 18 днів тому

      Glad you liked it!

  • @tushaljain5901
    @tushaljain5901 23 дні тому

    d option is also coming in the answer pleaese help me in that

  • @mveen
    @mveen 24 дні тому

    Really Helpful 😊

  • @a7prabhat21
    @a7prabhat21 24 дні тому

    ❤❤❤

  • @a7prabhat21
    @a7prabhat21 24 дні тому

    ❤❤❤❤

  • @vishnujangid5359
    @vishnujangid5359 25 днів тому

    👏

  • @TECHNICALEXPERT113
    @TECHNICALEXPERT113 25 днів тому

    he is covering the good questions but the main disadvantage of his channel is this that this person use 100% english not a single word of hindi. i saw this video 4-5 times still cant getting the concept. please use hindi in your lectures you will get more subscribers men . god bless you

    • @GateCsTOW
      @GateCsTOW 25 днів тому

      Hello there. All the videos are available in both of languages. Hindi and english. There is no video that's only in one language. And i think you are thinking we are a team. No brother I'm alone and the *this person * in video is only person managing everything that's why it's not possible to record more videos and reply to boubts whatsoever. Bhai ek sal k baad... 1000 se zada videos bnane k baad bhi aise comments aa rahe ki hindi me available nahi hai. Esiliye mene yt quit kr dia

    • @subratamahata3524
      @subratamahata3524 19 днів тому

      yes u are right

  • @fanofmahi9277
    @fanofmahi9277 25 днів тому

    Your explanation is really amazing sir. As you observe , I commented "amazing" on your every video, i watched till now. Yes!! Your knowledge is really amazing sir, THANK YOU SO MUCH SIR

    • @GateCsTOW
      @GateCsTOW 25 днів тому

      Thanks a ton, and good luck with prep bro.

  • @nishanthd7552
    @nishanthd7552 26 днів тому

    Very Good explanation! thankyou!

  • @shwetaarora28109
    @shwetaarora28109 27 днів тому

    subject name is COA not CAO !!

    • @GateCsTOW
      @GateCsTOW 25 днів тому

      Thanks for highlighting dear.

  • @shwetaarora28109
    @shwetaarora28109 28 днів тому

    answer for 1st part is 88 nd not 22 pls correct ur explanation

    • @GateCsTOW
      @GateCsTOW 27 днів тому

      Rechecked everything, it seems good. I couldn't find any errors or wrong explanation. Dear learner watch the video again or reffer any other source of your choice. Also keep in mind that pyq books have almost 1 error of every page.

    • @shwetaarora28109
      @shwetaarora28109 27 днів тому

      for 4 words u need to multiply by 4*22 and for next part too ans is 968 nd not 902 . Bcs its always given for single word accessing so u need to multiply by 4words

    • @shwetaarora28109
      @shwetaarora28109 27 днів тому

      many sites are posting the wrong answers. U need to refer the answers released by the GATE authorities itself

    • @shwetaarora28109
      @shwetaarora28109 25 днів тому

      @@GateCsTOW okay so u r right nd gate officials and experienced persons are wrong! got it

    • @achyutanandasahoo9761
      @achyutanandasahoo9761 7 днів тому

      ​​@@shwetaarora28109 What is the Answer according to GATE authority??

  • @ashishdwivedi4126
    @ashishdwivedi4126 28 днів тому

    Amazing explanation sir

    • @GateCsTOW
      @GateCsTOW 27 днів тому

      Thanks and welcome

  • @__harshchaturvedi_3931
    @__harshchaturvedi_3931 28 днів тому

    Thank you ❤

  • @fanofmahi9277
    @fanofmahi9277 Місяць тому

    But what if there are no options and it is numerical answer type ? , Could you pls upload a different approach solution

  • @apurv8790
    @apurv8790 Місяць тому

    if i take X=Q2 then work

  • @Unfilteredgulshan
    @Unfilteredgulshan Місяць тому

    Why you r not uploading new videos

    • @GateCsTOW
      @GateCsTOW Місяць тому

      Financial issues maan. Got bills to pay

  • @RishabhShukla-xy6yd
    @RishabhShukla-xy6yd Місяць тому

    Great explanation ❤

  • @raghadabd6884
    @raghadabd6884 Місяць тому

    Thank you so much

  • @rot1869
    @rot1869 Місяць тому

    What will be the throughput if the sender window size is greater than 1+2a

  • @rkverma3420
    @rkverma3420 Місяць тому

    Thanks much helpful