Questions tagged [check]

The tag has no usage guidance.

40 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
2
votes
2answers
91 views

2019 PSET4 SPELLER, I have no clue why it isn't working, I'm sure size and unload function is right, but unsure about load and check

// Implements a dictionary's functionality #include <ctype.h> #include <stdbool.h> #include <stdio.h> #include <stdlib.h> #include <string.h> #include <strings.h> #...
1
vote
1answer
198 views

pset5 cs50 does not handle basic words properly

Can you please help with the following issue with speller from pset5 in cs50: When I run the cs50 check, I get that it does not handle basic words properly, I am guessing, my check function is not ...
1
vote
1answer
225 views

PSET5 How can I test my code with small dictionary?

I'm trying to test my implementations of LOAD and CHECK with small dictionary of cs50 appliance, but it's look like I do the wrong thing... Someone can help me with that please! Thanks jharvard@...
1
vote
1answer
434 views

PSET5 How can CHECK have access to the loaded dictionary?

I'm now working on the implementation of CHECK subfunction. I think I'm on the good way, but my major problem at this moment is to link CHECK with the loaded dictionary. I'm pretty sure I can't access ...
0
votes
1answer
35 views

PSET6 DNA Almost done - matching not working correctly

I have been stuck with last part of the code that is supposed to match the DNA sequence from sequence.txt with the one in database.csv. It passes most of the tests in check50 and fails only in ...
0
votes
1answer
18 views

Can't check CAESAR pset2

I solved the Caesar problem and it works flawlessly. But I can not check it properly. The results are correct but ''' check50 cs50/problems/2021/x/caesar ''' says it is incorrect. If I view the ...
0
votes
1answer
23 views

Plurality error :( vote produces correct counts when all votes are zero

#include <cs50.h> #include <stdio.h> #include <string.h> // Max number of candidates #define MAX 9 // Candidates have name and vote count typedef struct { string name; int ...
0
votes
1answer
95 views

pset5 - almost all words misspelled

I'm having trouble with the implementation of the PSET5 spell check code. I've looked through a lot of CS50 Stack Exchange posts, but haven't found any help. The problem is either in the check or in ...
0
votes
1answer
261 views

pset3 (runoff) check50 is giving an error for print_winner

I can't find what's wrong with my code but check50 keeps telling me :( print_winner prints name when someone has a majority print_winner did not print winner of election :( print_winner returns ...
0
votes
0answers
320 views

FINANCE [UNIQUE constraint failed: users.username] Error encountered using check50

I have finally got my entire program working for PSET8 Finance. I receive no errors in my dev console and all functions are working correctly after registering 15 users. For some reason, though I get ...
0
votes
0answers
156 views

PSET8 CS50 Finance: /Check fails to run, does not catch or notify of duplicate usernames

I have been struggling with the check function in PSET8 for a few weeks now, and have run into various problems as I tried to work through my issues. Currently, it seems by check .get function does ...
0
votes
1answer
71 views

Javascript isn't running at all in pset8 check

I'm not sure how to run my javascript in pset 8. I used a normal script tag to link it in my register/html file. I'm not sure I need to link it from the application file. Do I need all the JS to be ...
0
votes
0answers
166 views

Pset8 - Check - Cannot get duplicate username to give javascript alert (that user must choose other username)

Below is a description of the problem, the "check() function" code, and the "register.html" file: Problem description: I haven't been able to write correct javascript (and maybe my check function ...
0
votes
1answer
105 views

cs50 pset5 hashtable check, misspelled more than expected

i have been working on the check for many days and not able to find why the misspelled word is more than stuff solution. Rest of the programs looks ok, and i used debug50 ,there is not too much clue. ...
0
votes
2answers
73 views

PSET5 Speller Trie Errors

So far, all other methods except check have already been implemented properly in my code. The problem with check is that it only returns true a lot fewer times than expected, which means that most ...
0
votes
0answers
45 views

can’t pass valgrind in pset5

I don’t know where is the error and when i use help50 that what i get and here is the code unsigned long hash(char* str); int count ; int table_size = 18788; typedef struct node { char word[...
0
votes
1answer
181 views

pset6 how do we check for string in mario

I've tried to find out how to check for string input for mario.py. I know to check for the range of integers when getting input from the user, but if they enter a string instead of a number, is there ...
0
votes
1answer
103 views

Trouble with Substrings in Check in Pset5

I have used a trie structure to implement my dictionary in pset5 and I believe my load() function is operating correctly, however I seem to be having trouble with checking substrings in the check() ...
0
votes
1answer
91 views

Logic Error in speller.c - Can't open text file and also have doubts about load() and check()

I wrote check() and then I tried to test speller with dictionary/small and a text file I'd written myself, but the text file couldn't be opened. Is there a problem with the way I implemented load() ...
0
votes
1answer
47 views

pset5 check fails possessives and substrings

Ok, so I'm stuck... I finally (hopefully?) got load to work correctly, ie no leaks or errors with valgrind, but now check is giving me a hard time. I only have 135 words misspelled; and it I fails ...
0
votes
1answer
77 views

My speller only deals with one word, despite me setting a new node for each iteration in load

This is my code for load and check... The speller finds only one word in the text then returns all the others as misspelt. I have seen someone here struggling with the same problem, and his/her issue ...
0
votes
1answer
88 views

pset5 spellcheck, problem with load

Could someone please review this code as I am not sure why am I getting segmentation fault while trying to use ' in words in a dictionary. I am attaching the code of my load function. //////////////...
0
votes
1answer
130 views

CS50 pset6 check50 errors

I have completed my first draft of pset6 web server and I have used valgrind to check my program for memory leaks of which there seem to be none. However, when I ran my server.c file through check50 I ...
0
votes
1answer
204 views

Mario pset1 a little hand please!

Spoiler alert code inside this link! !http://imgur.com/OIHvPFC I am having trouble with the mario, any tips of how i can get on with this? I have listed my integers at the start but maybe i over ...
0
votes
1answer
105 views

expected output, not standard error

My program compiles and runs fine. There isnt even much memory leak. But still it doesn't pass the cs50 check. Link to my check code
0
votes
2answers
365 views

CS50 Speller all words shown as misspelled

I'm having difficulty with CS50 speller. With the code below, all words are showing as misspelled, so there's obviously something (or many things) wrong with my load and/or check functions. I'd ...
0
votes
1answer
125 views

pset5 check-all misspelled?

I have the following code for check. I'm testing it against dictionaries/small and a test.txt and all words are coming back as misspelled? I don't understand why all words are coming back misspelled? ...
0
votes
1answer
137 views

Speller.c - need help on check

For an unknown reason some words that are in the dictionary and in the text file as well are marked as misspellings in the statistics. Though, the code passes check50 except the last paragraph saying ...
0
votes
0answers
248 views

pset5 check function skips some misspellings

I've ran the speller with the Austin Powers.txt, as so as i've ran the staff's solution. Mine speller catch's most of misspellings, but... Some small strings that are misspelled in the txt don't get ...
0
votes
1answer
108 views

pset5 Aborted (core Dumped)

I have been trying to debug this for over 2 days now. Can't seem to locate the reason why there's a segmentation fault. Running this returns a bunch of misspelled words plus an error message - ...
0
votes
0answers
159 views

pset5 load/check: seem to be inadvertently freeing my hashtable

I think I've implemented load in a (mostly) correct way. For the most part it seems to be sorting and loading into the hashtable correctly but I'm not sure. The problem I'm running into is that I ...
0
votes
0answers
40 views

Strcopy pset5 segfault

I get this seg fault in the strcpy line when I debug with gdb. int wordlen = strlen(word)+1; char worda[wordlen]; strcpy(worda,word); I tried with char* but even then it wasnt working. Full code ...
0
votes
0answers
124 views

Problem in recover in pset4

I have done my recover program and I get the 16 jpg images. They are well named and I can see them so the program is working correctly but when I check the program I get an error in the set recovers ...
0
votes
3answers
343 views

I can't check sort in Helpers.c

After reading the other questions, I still don't get how to check it. I tried to use gdb on ./find, but while I ran it, I could only see what was expected. Then, while typing n, it said "in fileops.c"...
0
votes
1answer
107 views

why check50 is not evaluating corectly for my question

I have tried to approach the question in move simplifir=ed way and i have created an array and declared it globally. my programme is correctly responding to all the asked questions but still I'm not ...
0
votes
1answer
124 views

Why check50 is not evaluating true when my programme is corectly responding to all the asked questions?

When i run check50 it shows everything in red and when i open the given link it shows the below image. I have removed the printf commands also but still then it is showing the same problem. someone ...
0
votes
0answers
249 views

pset6 check function - student result set doesnt match staff - works on small test, fails on big

I have a version of dictionary.c that has all of the functions completed and compiling. When I run ./speller on my small test sets it completes succesfully. When I run it using the following test, ...
0
votes
0answers
201 views

check() doesn't work properly

check produces wrong output I have tried gdb on the first words and everything seemed right. here is some psuedocode. // while in hashtable // if the word is found return true // if we reach ...
0
votes
1answer
226 views

Segfault Pset6 Check()

I receive a segfault at this line of code if (pathCheck -> children[charVal] == NULL) { return false; } pseudocode buildup: initialise pathCheck to NULL while character is ...
-1
votes
1answer
422 views

Different methods for transforming a string to lower case in C

In the check() function I've figured that I should transform the input word to all lower case. To do that I wrote this: int wlen = strlen(word); char word1[wlen+1]; //transform the word to all ...