0

I am getting lack of argv[1] arguments handling after running check50 on caesar cipher problem in pset2, what does this mean? Please somebody help me figure out this error not able to fix this.

1 Answer 1

1

This can be due to several things.

The first can be that your program keeps running even when you don't provide a command line argument.

Or can be also that when you don't provide a command line argument your program is exiting with a wrong error code.

Another possibility is that your program is not printing something in the terminal to tell the user that he or she has not provided a command line argument.

Here is a part of the specification for the problem set that explains how the program should behave in this aspect.

Anyhow, your next goal is to write, in caesar.c, a program that encrypts messages using Caesar’s cipher. Your program must accept a single command-line argument: a non-negative integer. Let’s call it k for the sake of discussion. If your program is executed without any command-line arguments or with more than one command-line argument, your program should yell at the user and return a value of 1 (which tends to signify an error) immediately as via the statement below:

return 1;

You can see how the staff implementation behaves when this happens with the command:

~cs50/pset2/caesar
1
  • Thanks buddy I did not check the condition for one command line argument & my program was constantly running.thanx for help. Commented Jan 11, 2015 at 4:01

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .