Skip to main content
1 vote

printf printing an @ after a string

From man printf s If no l modifier is present: The const char * argument is expected to be a pointer to an array of character type (pointer to a string). Characters from the array are written up to (...
DinoCoderSaurus's user avatar
1 vote

Help In Solving Memory Leak For PSET5

I just found a subtle error in the check function. The allocated size for the string is wrong. It's should've been word_copy[n + 1] instead of word_copy[LENGTH]. Thank you for your input though. I'm ...
Nobody's user avatar
  • 23
1 vote
Accepted

Help In Solving Memory Leak For PSET5

The problem is that the tree isn't being freed. You could add a printf statement inside the unload function's loop to show it. The cause is interesting, it leads to unpredictable results in a full ...
Cliff B's user avatar
  • 69.3k
1 vote

CS50 2019 Verified Certificate Missing

This is a known issue with edX. Please contact them via [email protected] so they can give you a link.
curiouskiwi's user avatar
  • 18.7k
1 vote
Accepted

Receiving EOF when I execute check50 (Readability)

I found the mistake was in a space between %i\n and ", in the line printf("Grade %i\n ", (int) round(index)); The problem was solved when rewriting to: printf("Grade %i\n", (...
Martin Birkeland's user avatar
1 vote
Accepted

pset3 resize less

Have you looked at the actual hex data of the file instead of the image? When looking at the image, the header data (assuming it's correct) will only allow the display of the specified amount of data ...
Cliff B's user avatar
  • 69.3k
1 vote
Accepted

crack.c: No response 😒

I'd remove the space from the pool of valid password characters, and try again. Maybe you saw a less than 5 character password with some space character in front. You don't have a break; after done = ...
Blauelf's user avatar
  • 21k
1 vote
Accepted

Bug? My Crack code was accepted though it doesn't work properly

There is no automated grading for crack so if you submit a solution, we expect that you will have tested it and it works per the spec. As such, you will get 5/5 upon submission.
curiouskiwi's user avatar
  • 18.7k
1 vote
Accepted

check50 is being silly

While the output from your program may be encoding the plaintext, the problem lies elsewhere. The program spec says to prompt for input. The code above merely waits for input, without a prompt. ...
Cliff B's user avatar
  • 69.3k
1 vote
Accepted

PSET3 Game Of Fifteen tiles not swapping! (no illegal function but no change in board)

Well, now you correctly check if the move tile and the blank tile are next to each other. It's not the shortest and not the most stylish way to do it, but OK. Then, in theory, you need to swap these ...
obesman's user avatar
  • 1,139
1 vote
Accepted

Submit page tells me that my submission is late

The 2016 course deadline has passed. The 2017 submissions haven't opened yet. But you don't have to resubmit any psets that have already been graded, as your gradebook will carry over to the 2017 ...
curiouskiwi's user avatar
  • 18.7k

Only top scored, non community-wiki answers of a minimum length are eligible