Search:

Type: Posts; User: ammochck21

Page 1 of 4 1 2 3 4

Search: Search took 0.01 seconds.

  1. Replies
    11
    Views
    3,038

    Warnings 1,2,3,4: warning: comparison between...

    Warnings 1,2,3,4: warning: comparison between pointer and integer



    if (command[2] == '/') {



    else if (command[2] == '*') {
  2. Replies
    11
    Views
    3,038

    I will post the error messages in a second but I...

    I will post the error messages in a second but I noticed that when I put the ; back in after the if statement:


    if(strcmp(command[0], "cd") == 0); { //SEG FAULT HERE!!!
    dir =...
  3. Replies
    11
    Views
    3,038

    Seg Fault

    Ok thanks for your help....cant believe I couldnt see the semi-colon! And I did have command in there...dont know why its not in there in this code...I had it defined somewhere else...which was...
  4. Replies
    11
    Views
    3,038

    Getting a seg fault

    This is driving me nuts! I dont know much about C so I cant find what I am doing wrong but I have debugged it to the point that I know where I am getting a Seg. Fault but dont know why:



    void...
  5. Replies
    11
    Views
    1,317

    Tabstop you always help me! however, what i...

    Tabstop you always help me!

    however, what i have in the pseudocode is what i have in the program but it is STILL storing the stupid neg sign! I dont know whats going on. Maybe my for loop is...
  6. Replies
    11
    Views
    1,317

    well if i do nothing then it will still read it...

    well if i do nothing then it will still read it in and put it in spot 1. I know i need it for future tasks in this assignment, but I do not want it to be stored in the array, at all. That is where...
  7. Replies
    11
    Views
    1,317

    I got my average function working, but I still...

    I got my average function working, but I still cant do anything with the neg. sign. I tried having a string variable hold the neg. sign, but then it prints 0's in front of all my numbers. Please...
  8. Replies
    11
    Views
    1,317

    ok and thats my problem. I only know how to do...

    ok and thats my problem. I only know how to do cin.ignore, but the number has already been read in, so how would I do ignore? you cant just do ignore() right?
  9. Replies
    11
    Views
    1,317

    well i started doing that, but what happens after...

    well i started doing that, but what happens after the flag gets set to true. Does the neg sign get ignored after that?
  10. Replies
    11
    Views
    1,317

    Struct help!

    Hey everyone- I am having trouble with structs...grrrr. I am trying to ignore the - sign in the beginning of the number so I can compute the average. I cant seem to remember how to just ignore the...
  11. Replies
    2
    Views
    1,296

    Explanation of Code

    I am having trouble seeing what this code is doing. I keep getting flag[i] as the only on going into the critical section, which obviously means I am missing something! This isnt homework and I...
  12. Replies
    7
    Views
    1,736

    Thanks that makes sense to me! So then would I...

    Thanks that makes sense to me! So then would I still need that while loop I have right above it if I do all string compares?
  13. Replies
    7
    Views
    1,736

    cant get my input to work...

    hey guys,

    ok right now I am trying to enter some input, for example, 'cd'. right now it will get and print the current directory I am in. but when I enter anything, it exits out of my prog....
  14. Replies
    8
    Views
    5,415

    and what is pipecount for? i know pipe() is...

    and what is pipecount for?

    i know pipe() is used for process to communicate with each...right? my TA said I needed pipecount in there, but i guess I dont really understand it....boy do I feel...
  15. Replies
    8
    Views
    5,415

    yeah i know i took those out...

    yeah i know i took those out...
  16. Replies
    8
    Views
    5,415

    Ok well going back to my read_parse....... can...

    Ok well going back to my read_parse.......

    can you explain to me what char *comm, char command[], and input_string[mystring] should be doing with relation to each other?

    I think I am confusing...
  17. Replies
    8
    Views
    5,415

    Need help with chdir()

    Hey all,

    This is my first time programming in C, but i am used to C++ so i am trying to use the same layout as I would with C++ for my program. I am a little confused about the chdir() part of...
  18. Replies
    24
    Views
    2,035

    I got it...nevermind :) thanks so much!!!

    I got it...nevermind :) thanks so much!!!
  19. Replies
    24
    Views
    2,035

    ok well your right it works now...i dont know if...

    ok well your right it works now...i dont know if removing the semicolon made it work but it does.

    i now have to add all of the sum's to get a final total...any suggestions?



    Job# ...
  20. Replies
    24
    Views
    2,035

    for the S input...it will read te first number...

    for the S input...it will read te first number which tells it how many sizes it need to read in.

    So for S 5 12 3 10 7 16

    it reads in num which is 5.
    it should go through the for loop 5...
  21. Replies
    24
    Views
    2,035

    so what do i need to do for the S loop...i see...

    so what do i need to do for the S loop...i see what your saying...but i dont know what to do to fix it...i ran through it by hand...and it worked...but I am also not a computer... thanks!
  22. Replies
    24
    Views
    2,035

    I cant BELIEVE it was that tiny little...

    I cant BELIEVE it was that tiny little thing!!!!!! THANK YOU!!!!!!!!!!!!!!!!! It works now! :)
  23. Replies
    24
    Views
    2,035

    ok here is the whole code I have written.....this...

    ok here is the whole code I have written.....this wont work for the commented out parts:




    cin >> jobnum;
    while (!cin.eof())
    {
    cin >> code;
    while(code!='Q')
  24. Replies
    24
    Views
    2,035

    when i read in the size and printed out to see...

    when i read in the size and printed out to see what its reading in...it only prints an M.....the spaces get skipped with what we are doing....so its not really going through the for loop until i =...
  25. Replies
    24
    Views
    2,035

    well its reading the first M....but then thats...

    well its reading the first M....but then thats it....its not going back through the loop to get the other sizes...yes S = 35, M=100 and L = 500. so since the first data set is

    P 3 M M S it...
Results 1 to 25 of 86
Page 1 of 4 1 2 3 4