Search:

Type: Posts; User: gajya

Page 1 of 4 1 2 3 4

Search: Search took 0.01 seconds.

  1. Replies
    5
    Views
    4,613

    How do you do if number is not in sequence ? 2...

    How do you do if number is not in sequence ?

    2
    2 9
    2 9 3
    2 9 3 6
    2 9 3 6 5
  2. Replies
    5
    Views
    4,613

    I can do that but I am looking for a function ...

    I can do that but I am looking for a function


    #include<stdio.h>

    int main ()
    {
    int i;

    int array[5] = {1};
  3. Replies
    5
    Views
    4,613

    static array list

    I'm trying to make static list that can add element in list. I know that's know the good way to make list but it's just experiment

    only 5 digits allow in list

    Program supposed to give result...
  4. Thread: FIFO Queue

    by gajya
    Replies
    21
    Views
    11,241

    I have spent enough time to solve problem but...

    I have spent enough time to solve problem but program doesn't give expected output


    #include<stdio.h>
    #define CAPACITY 5
    #define True 1

    struct Queue {
    int data[CAPACITY];...
  5. Thread: FIFO Queue

    by gajya
    Replies
    21
    Views
    11,241

    There was some misunderstanding ...

    There was some misunderstanding


    #include<stdio.h>

    #define CAPACITY 5
    #define True 1

    struct Queue {
    int data[CAPACITY];
  6. Thread: FIFO Queue

    by gajya
    Replies
    21
    Views
    11,241

    Thanks for excellent advice. I have created one...

    Thanks for excellent advice. I have created one function to print enqueue. I want to print enqueue a value


    #include<stdio.h>

    #define CAPACITY 5
    #define True 1

    struct Queue...
  7. Thread: FIFO Queue

    by gajya
    Replies
    21
    Views
    11,241

    sorry but still I don't have clear idea ...

    sorry but still I don't have clear idea


    #include<stdio.h>
    #include<stdlib.h>


    #define size 10
    #define True 1
  8. Thread: FIFO Queue

    by gajya
    Replies
    21
    Views
    11,241

    I don't understand these two lines exactly what...

    I don't understand these two lines exactly what happens


    #include<stdio.h>

    #include<stdlib.h>


    #define size 10
    #define True 1
  9. Thread: FIFO Queue

    by gajya
    Replies
    21
    Views
    11,241

    @Salem I think I have done ...

    @Salem I think I have done


    #include<stdio.h>
    #include<stdlib.h>

    struct Queue {
    int data[10];
    int front;
    int back;
  10. Thread: FIFO Queue

    by gajya
    Replies
    21
    Views
    11,241

    Am I doing that ? Both pointers initially at 0 ...

    Am I doing that ?
    Both pointers initially at 0


    #include<stdio.h>

    #include<stdlib.h>

    struct Queue {
    int data[10];
  11. Thread: FIFO Queue

    by gajya
    Replies
    21
    Views
    11,241

    I think I have done ...

    I think I have done


    #include<stdio.h>#include<stdlib.h>

    struct Queue {
    int data[10];
    int front;
    int back;
    };
  12. Thread: FIFO Queue

    by gajya
    Replies
    21
    Views
    11,241

    Salem, Thank you What function...

    Salem, Thank you

    What function queueInit(struct Queue *q); supposed to do ?
  13. Thread: FIFO Queue

    by gajya
    Replies
    21
    Views
    11,241

    FIFO Queue

    I am trying to understand queue in c language. I have gone through page Programming Concepts: Queues - Wikibooks, open books for an open world


    #include<stdio.h>

    #include<stdlib.h>
    ...
  14. I have tried to write code, see post 1 But having...

    I have tried to write code, see post 1 But having trouble making full code So I asked how to make a function for list
  15. My ATTEMPT to solve problem 16008 I have...

    My ATTEMPT to solve problem

    16008

    I have already shown my code. I have only problem with code
  16. Function to add node between first and last node

    How to make function that can add the new node between fist and last node

    for example

    20 40
    add new value 30

    list 20 30 40

    add new value 50
  17. Replies
    2
    Views
    4,448

    Every function call new node will add to list....

    Every function call new node will add to list. The pointer will always point to the address of the next node. when node is last node pointer will point to null. But i don't think my function is doing...
  18. Replies
    2
    Views
    4,448

    Add not after previous node

    Hi,

    I want to make function that add new node after previous node. if the list is empty add the first node and then add new node after previous node


    #include <stdio.h>#include <stdlib.h>

    ...
  19. Replies
    6
    Views
    5,620

    alright I am converting logic into code but I am...

    alright I am converting logic into code but I am surprised that you did not use the else if statement


    #include<stdio.h>

    int main ()
    {
    int n = 3;

    if ( n == 1 )
  20. Replies
    6
    Views
    5,620

    I shown my best making diagram I don't even know...

    I shown my best making diagram I don't even know if this can happen real once I get the idea, I will try to make more diagrams




    15999
  21. Replies
    6
    Views
    5,620

    Flow diagram If Elseif - Else statement

    I have made it flow diagram and I want understand how it would be look in code structure

    15998

    What would be the structure of the code for this function flow diagram ?


    #include<stdio.h>...
  22. Replies
    1
    Views
    3,931

    Set, Clear and Toggle a specific bit

    Are all my operations correct if I want to Set, Clear and Toggle a 7 bit

    clear 7th bit

    1010 1001 byte
    0000 0000
    ---------- AND logic
    1000 0000
  23. Replies
    6
    Views
    5,837

    it works if I declare function before main

    it works if I declare function before main
  24. Replies
    6
    Views
    5,837

    ohh This means that I can only use the global...

    ohh This means that I can only use the global variable in the same file where it is declared. In this program, I have declare x in main.c , so I cannot use x in another file foo.c.


    If I want to...
  25. Replies
    6
    Views
    5,837

    But my experiment is not giving such a result ...

    But my experiment is not giving such a result

    result

    foo.c: In function 'foo':
    foo.c:3:2: error: 'x' undeclared (first use in this function)
    x = 0;
    ^
    foo.c:3:2: note: each undeclared...
Results 1 to 25 of 82
Page 1 of 4 1 2 3 4