Question Mark not getting show in console

Hello I am trying to make a help screen for my project so user can use a switch such as exename.exe /? the problem is when I am checking the question mark is outputting as the letter w

Here is the code from my main function.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
    int x = 1;
    char param;
    char *in_file;
    char *out_file;
    char *lzfile = "C:\\out\\ben\\addnums.txt";

    while(x<argc)
    {
        switch(argv[x][0])
        {
        case '-':
            param = tolower(argv[x][1]);

            if(param == 'i')
            {
                x+=1;
                in_file = argv[x];
            }
            else if(param == 'o')
            {
                x+=1;
                out_file = argv[x];
            }
            else
            {
                PAbort(1);
                break;
            }
            break;
        case '/':
            cout << argv[x][1]; // Keeps outputting w and not ?
        }
        x++;
    }


Thanks.
Topic archived. No new replies allowed.