All Questions
Tagged with caesar caesar-cipher
14 questions
0
votes
1
answer
100
views
I'm stuck at PSet 2 Caesar Cipher: The alphabets don't follow my modulo 26. It goes beyond it, printing non-alphabetic characters
The crux is at the last part where I've commented "CONVERT PLAINTEXT TO CIPHERTEXT"
The variable asciiValue holds the, well, the asciiValue of the enciphered character. As you can see, I've ...
0
votes
1
answer
57
views
Errors in Caesar pset2 and Wrong Output
I am almost finished with Caesar only a couple of issues persist which I am unable to overcome
Here is my code -
#include <stdio.h>
#include <cs50.h>
#include <stdlib.h>
#include <...
0
votes
2
answers
137
views
Caesar pset2 How to Reprompt user for Command Line Argument?
I have started working on Caesar and I am stuck with how to repromt user for a command line argument incase they input some wrong values.
Here is the code i wrote and I can't find any apparent errors
#...
0
votes
1
answer
180
views
Caesar problem: Validating keys
I don't really know what went wrong here.
I'm trying to test if the second word of the command line contain all digit. So I tried to check every character in argv[1] with the isdigit function by ...
0
votes
1
answer
177
views
\ expected output, but not "plain text: "
I coded this, and all works fine when I insert the same examples given in the specs, but somehow the CS50 checkers reads the "plaintext: " string as the solution! Anybody wise and kind to give a hand? ...
0
votes
1
answer
66
views
Pset2 Caesar Cipher - compiles but doesn't look right
I'm really stuck on Caesar Cipher. It compiles but the ciphered text doesn't look like it should. Instead of one line of text, every character gets printed one by one.
https://sandbox.cs50.net/checks/...
0
votes
1
answer
306
views
Caesar Cipher Formula Question
This is the code I have:
// Osman Zakir
// 10 13 2016
// Introduction to Computer Science
// Problem Set 2, caesar.c
// Take the key for the cipher from the user as a command-line argument and use it ...
0
votes
1
answer
266
views
Not sure why I keep getting the \expected output not prompt for input
Not sure why I get that error. It is clearly something wrong with my code and the way it is organised but I cannot pinpoint it.
#include <cs50.h>
#include <math.h>
#include <stdio.h&...
0
votes
1
answer
104
views
Spoiler - PSET2 Caesar - why does plain text change when ciphertext changes?
while doing Pset2 Caesar, I came across this strange situation where my plaintext would change whenever my ciphertext changes.
Ultimately my program compiles and passes check50, however, if the ...
0
votes
1
answer
50
views
caesar pset 2 non-numeric key error even when it works well when i try it myself
Here is my code which works well even with non-numeric key.
#include <stdio.h>
#include <cs50.h>
#include <stdlib.h>
#include <ctype.h>
#include <string.h>
bool key_check(...
0
votes
2
answers
82
views
PSet2 Caesar - User Defined Function Issue
I'm a newbie with what seems to be a syntax issue in my user defined function.
Currently my code --and the error is the following:
...the problem seems to be the semicolon at the end of line 39.
But ...
0
votes
1
answer
960
views
problem set 2 caesar check :( handles non-numeric key timed out while waiting for program to exit
I have gotten my code to work for the caesar problem in problem set 2. However, when i check through check50 I run into this error: :( handles non-numeric key
timed out while waiting for program ...
0
votes
0
answers
94
views
segmentation error in caesar, I am unable to understand why
Here is my code:
#include <stdio.h>
#include <cs50.h>
#include <math.h>
#include <string.h>
#include <stdlib.h>
#include <ctype.h>
int main(int argc, string argv[]...
0
votes
1
answer
253
views
Problem with caesar cipher encryption
I'm trying to solve pset2 Cesar encryption.Everything seems fine and encryption is working but when I hit check50 I get errors:
:( encrypts "a" as "b" using 1 as key
expected prompt for input, ...