Search:

Type: Posts; User: Max

Page 1 of 5 1 2 3 4

Search: Search took 0.01 seconds.

  1. Thread: fix this code

    by Max
    Replies
    1
    Views
    940

    thanks for the help.....but what if I want the...

    thanks for the help.....but what if I want the user to type parenthesis like largest (4,5,6,7,9)

    your code get rids of the commas. I tried to get rid of the () but it does not seem to work, I...
  2. Thread: cout

    by Max
    Replies
    5
    Views
    981

    It did not work!

    It did not work!
  3. Thread: fix this code

    by Max
    Replies
    1
    Views
    940

    fix this code

    The user need to type largest (3,7,11,9) at the prompt. It means that I have 3 numbers in the array and I need to find the largest integer in the array containing 7, 11, 9.

    I was able to get the...
  4. Thread: cout

    by Max
    Replies
    5
    Views
    981

    It did not work..........

    It did not work..........
  5. Thread: cout

    by Max
    Replies
    5
    Views
    981

    odd...someone played with my original post??!!!??...

    odd...someone played with my original post??!!!??

    basically what I am trying to do is change this c code into c++

    if (k%2==0) printf("%*s", -LINEWIDTH/2,t[k]);
    else printf("%s\n",t[k]);...
  6. Thread: cout

    by Max
    Replies
    5
    Views
    981

    cout

    how can I print exactly like this:

    1234 5
    23 10
    5 600

    notice how the numbers in the second column are alligned

    I don't want to print like this
  7. Thread: c to c++

    by Max
    Replies
    10
    Views
    1,260

    c to c++

    What is the equivalent of toupper, strcpy and strtok in C++ ?
  8. Thread: 2 way linked list

    by Max
    Replies
    2
    Views
    2,928

    2 way linked list

    This is a linked list. I am trying to input employee names and addresses. This program works so far but I am having two problems that I need help with

    1- How can I store the full street string...
  9. Thread: scan a string

    by Max
    Replies
    4
    Views
    3,477

    scan a string

    What is wrong? I am trying to read a user input. The input is a street address ex: 401 North Ave.

    I can't get it to scan???

    The street variable is part of a structure that I am using in a...
  10. Thread: single linked list

    by Max
    Replies
    1
    Views
    1,772

    single linked list

    If this is a single linked list with a head pointer

    How can I change the pointer to point to Tail?




    #include <stdio.h>
    #include <string.h>
    #include <stdlib.h>
  11. Replies
    14
    Views
    2,198

    Thanks all for your help!!!!

    Thanks all for your help!!!!
  12. Replies
    14
    Views
    2,198

    My program works fine...I just had to fix the...

    My program works fine...I just had to fix the freeing of memory and the feof line...

    However, it is not the printing the words in order.

    Is this normal for a linked list...if not how can I...
  13. Replies
    14
    Views
    2,198

    OK here is my updated link list code. It...

    OK here is my updated link list code. It compiles with no errors but it does not run....it freezes.

    I get the feeling it has to do with file IO...I am not reading words from the file correctly!!...
  14. Replies
    14
    Views
    2,198

    So how do I turn my program into a linked list?

    So how do I turn my program into a linked list?
  15. Replies
    14
    Views
    2,198

    Thanks Magos So basically by initiallizing the...

    Thanks Magos

    So basically by initiallizing the arrays to NULL I have now a linked list!!

    If i put a -1 in sizeof(line-1) I don't get all the words printed on the screen!!

    Also how do I...
  16. Replies
    14
    Views
    2,198

    one way linked list

    I am trying to read text from a file
    The file has text written in that manner

    hello is
    my Sam
    name

    I want to store each of these words in a node in a one way linked list
    ...
  17. Thread: string

    by Max
    Replies
    3
    Views
    971

    string

    I know that I can use string instead of char when declaring a char or an array

    So here is a function prototype written in c

    void decrypt(const char in[],char out[]);

    can I re-write it in c++...
  18. Thread: file I/O

    by Max
    Replies
    3
    Views
    1,018

    I am trying to insert into the output file...

    I am trying to insert into the output file letters:

    The input file has numbers like that:
    12
    13
    14
    15

    I want to create an output file with extension .new (which I did!)that assign a letter...
  19. Thread: file I/O

    by Max
    Replies
    3
    Views
    1,018

    OK I have reached a dead end..... How can I...

    OK I have reached a dead end.....

    How can I change what the file extention that teh use typed at the comand prompt.

    ex: if typed output.txt, I want my programto create output.new
    currently...
  20. Thread: file I/O

    by Max
    Replies
    3
    Views
    1,018

    Thanks Salem.... How do I put the \0 at the...

    Thanks Salem....

    How do I put the \0 at the end of the string....(I can never get it!!!!) and I thought c does it automatically

    Yes you are right I want to change any file that the user uses...
  21. Thread: file I/O

    by Max
    Replies
    3
    Views
    1,018

    file I/O

    I am trying to write the content of a document that the user specify into a new file which has teh same name but with teh extension .new

    How can i do that? I have marked <======= to show where...
  22. Replies
    2
    Views
    1,391

    Thanks Prelude......

    Thanks Prelude......
  23. Replies
    2
    Views
    1,391

    printing a number that starts with 0

    I am trying to print a number that starts with 0 and incremented 100 times

    ex: 0200, 0201, 0202,.......

    I used a for loop but the program outputs some other weird numbers....I guess it does...
  24. Thread: file I/O

    by Max
    Replies
    3
    Views
    843

    Thanks shiro...... but now I want to change...

    Thanks shiro......

    but now I want to change the program...I want to write 1 to 120 at the biginning of the line to label it and make sure that there are 50 bytes allocated after each number in...
  25. Thread: file I/O

    by Max
    Replies
    3
    Views
    843

    file I/O

    I want to write in a file 120 lines with 50 dots on each line including the null terminator.

    I started my code but it prints incorrectly.....what is wrong in my code....



    #include <stdio.h>...
Results 1 to 25 of 110
Page 1 of 5 1 2 3 4