All Questions

Filter by
Sorted by
Tagged with
0
votes
0answers
1 view

error: use of undeclared identifier 'argv' in Caesar

I dont know why this is wrong because it always says Caesar.c:17:13: error: use of undeclared identifier 'argv' even though it works for the ones before. #include <cs50.h> #include <stdio.h&...
1
vote
0answers
9 views

PSET4 — Filter (more) — Edges Error

I'm currently working through the filter problem, and I'm not sure why it's not working on the pixels on the edge (it also seems to only be incorrect on the B value in RGB). This is the message I'm ...
0
votes
1answer
12 views

Why is my lab1 code failing to pass one test in check50?

First, let me share my code: #include <cs50.h> #include <stdio.h> int main(void) { int x = 1, y, n = 0, year; do { x = get_int("Enter the starting population size:...
0
votes
1answer
13 views

Help with recover.c! I tried to use recursion

The lines which attempt to stop the recursion using EOF don't seem to work. Can anyone help me see why? #include <stdio.h> #include <stdlib.h> #include <stdint.h> #include <string....
0
votes
1answer
16 views

pset5 - speller - recursion

// Implements a dictionary's functionality #include <stdio.h> #include <stdbool.h> #include <stdlib.h> #include <string.h> #include <strings.h> #include "dictionary....
0
votes
0answers
12 views

CS50 Web Wiki Project Edit Form adding extra lines to textarea

Everything is working properly in terms of editing and redirects, however there is a strange occurence where multiple extra empty lines are added between each line of the markdown content everytime ...
0
votes
1answer
26 views

I don't understand the comments from check50 on my lab 1 submission. could anyone help please?

This is my code #include <cs50.h> #include <stdio.h> int main(void) { // TODO: Prompt for start size int s; do { s= get_int("Start size: "); } ...
0
votes
1answer
10 views

Having Trouble using StrCpy with Command Line argument for Problem Set 2 Caesar. Trouble with Array

Hello I'm still fairly raw at this coding thing so i'm sure im making rookie mistakes. I'm doing Problem Set 2 caesar and I've hit a wall and haven't been able to move forward. What I have been trying ...
0
votes
1answer
21 views

cs50 pset3 runoff tabulate function help

I have been stuck at the tabulate function for quite some time, I'm able to code all the other functions except for this tabulate functions. If possible do help me look to see what wrong with the ...
0
votes
1answer
25 views

Plurality print_winner function gives one error

This is my print_winner function void print_winner(void) { int winner_vote; for (int i = 0; i < candidate_count; i++) { for(int j = i + 1; j < candidate_count; j++) {...
0
votes
0answers
16 views

Python with django

Please provide me tips or suggestion for below scenario: I want to build code for below scenario and need help. In system 2 folders ( Visiting cards[ Images], Resumes [PDF, DOCX] ) Using Django, On ...
0
votes
1answer
10 views

Does anyone know how to use Django on CS50 IDE?

I can’t seem to run Django on CS50 IDE. I downloaded Django without a problem. I can create a Django app without a problem using "python manage.py startapp hello". But the problem comes when ...
0
votes
0answers
3 views

Does anyone know how to use Django with minimal setup? Perhaps in a cloud environment or some IDE?

I can't seem to set up Django on my computer. As for running on my computer, I have just installed python and I think pip comes along with it? So I checked if I had pip installed using the command &...
0
votes
0answers
5 views

Does anyone know why my degrees program does not work when I use a Queue Frontier instead of a Stack Frontier?

This was the error in the terminal. Loading data... Data loaded. Name: Kevin Bacon Name: Tom Cruise Traceback (most recent call last): File "/home/ubuntu/AI/degrees/degrees.py", line 208, ...
0
votes
1answer
11 views

Why is the reference variable for dynamically allocated memory lower on the stack?

#include <stdio.h> #include <stdlib.h> #include <string.h> int main(void) { int n = 5; char str1[n]; char *str2; char str3[] = "World!"; // ...
0
votes
1answer
12 views

Recover - PSet 4

I am for some reason unable to generate any jpgs with my code; I think there's a mistake in the logic somewhere? Would be very grateful for some hints! Thank you! #include <stdio.h> #include <...
0
votes
1answer
9 views

get_string function not working on pset6 2020

here is the problem ~/ $ python hello.py Traceback (most recent call last): File "/home/ubuntu/hello.py", line 1, in <module> answer = Get_string("what is your name") ...
0
votes
1answer
17 views

pset 3 tideman print winner does not exist despite being declared

I have such a strange behavior here in pset 3, tideman. I am doing the print_winner function because check50 says everything else is fine, but when i run the program it looks like print_winner does ...
0
votes
2answers
20 views

PSET9 Finance: Check50 says Buy doesn't handle fractional/invalid shares, but when I try these things my page does reject them. Why check50 no like?

I have been using some of the html from the cs50 finance example page: https://finance.cs50.net/buy (which is permitted by CS50) I think it may be at the root of the problem. Here's the relevant html ...
0
votes
0answers
11 views

How can I Join 4 Data Tables via 1 Linking Table, where an INT column can be a Foreign Key to either of the 4 Data Tables

I have hit a dilemma with Flask-SQLAlchemy.... So my issue is that in Flask-SQLAlchemy I have 5 models which need to interact with one another, 4 main models (let's call them Model1, Model2, Model3 ...
0
votes
1answer
20 views

Problem set 1, Cash executuion issue

My code is as following: #include <stdio.h> #include <cs50.h> #include <math.h> int main(void) { //prompt for change float a = 0; int c = 0; ...
0
votes
1answer
25 views

cs50 plurality non-void function does not return a value in all control paths error

I'm currently trying to do cs50 pset3 plurality problem and I have unfortunately ran into this error which I do not know how to overcome. The error is "non-void function does not return a value ...
0
votes
1answer
10 views

Pset5 - Speller - Seg fault

I'm getting a segmentation fault when running this. Valgrind reports no errors, but a leak of 1,080 bytes at two blocks, with 5 allocs and only 3 free'd. Below is my load function and below that are ...
0
votes
0answers
23 views

Tideman error: :( lock_pairs skips final pair if it creates cycle

It would be amazing if someone had the time to look through my code for the Tideman exercise :D I get the following error: :( lock_pairs skips final pair if it creates cycle lock_pairs did not ...
0
votes
0answers
12 views

I need to create a generic list in java to add objects to list?

public static void main(String args[]) { CheckingAccount ca = new CheckingAccount(); SavingsAccount sa1 = new SavingsAccount(); SavingsAccount sa2 = new SavingsAccount();// TODO: create 3 ...
0
votes
1answer
11 views

Undeclared identifier error inCS50 Pset2 caeser

I keep getting 2 undeclared identifier errors on these respective lines line 48: printf("ciphertext:%c", ((p[n] - 65 + k) % 26) + 65); line 54: printf("ciphertext:%c", ((p[n] - 65 +...
0
votes
1answer
15 views

pset2 substitution Cant figure out the segmentation fault

I've been trying to break it down into parts but I can't figure out why I keep having a segmentation fault. I've watched the lecture but I can't figure out where to put the breakpoint to find it. Im ...
0
votes
0answers
14 views

Text to Speech Plugin for Scratch Not Working

I am following along with Lecture 0 and am nearly finished. I have encountered no problems using Scratch until the exercise in the lecture to use the Text to Speech Plugin. Details of Development ...
0
votes
1answer
25 views

pset4 Blur calculation does not work properly

for some reason I can't get my calculation for the blur value running. The pictures are really odd and contain crazy colors. Any ideas to why this could be the case? I compared it already to working ...
0
votes
1answer
13 views

make mario won't work but i'm in the correct directory

make mario won't work but I'm in the correct directory. I haven't even started writing the solution properly as I'm stumped on getting it to compile. Any suggestion? I tried restarting the IDE and ...
0
votes
1answer
28 views

Mario less, struggling with nested FOR loop

hello I have got my code to work but don't understand logic, I found a flow cart for how nested for loops work and with that I was able to mix things around until I got it to output correctly but ...
0
votes
0answers
25 views

what is the c program of the question below;

What is the c program that will print numbers divisible with 7,13 and 19 and lower than given number. Numbers must be from Highest to lowest
0
votes
1answer
14 views

How can i arrange the output in decending order In this program? [closed]

#include <stdio.h> int main() { int n,i; printf("Enter a number: "); scanf("%d",&n); for (i=0; i<=n; ++i) { if (i%(7*13*19)==0) { ...
0
votes
1answer
9 views

IDE.CS50.io can't get FireFox to full screen. Tried the F10 and F11

I'm trying to get Firefox to display IDE.CS50.IO in to full screen mode, which I thought was F10 or F11 and neither works. Thank you kindly, John
0
votes
1answer
15 views

For finance, does anyone know why my page for selling stocks does not work?

Here is my python code. @app.route("/sell", methods=["GET", "POST"]) @login_required def sell(): """Sell shares of stock""" if ...
0
votes
1answer
21 views

For finance, does anyone know why my page to buy stocks does not work?

Here is my python code @app.route("/buy", methods=["GET", "POST"]) @login_required def buy(): """Buy shares of stock""" if request....
0
votes
1answer
25 views

Pokedex keeps stopping (Android)

In Pokedex pset ,after implementing searching feature for the app , the app got successfully compiled in Android studio when I clicked on "run app" but the app won't open. I'm getting ...
0
votes
1answer
23 views

cs50 mario MORE comfortable need LOTS OF HELP

so ive been stuck on this problem for a about a week, took lots of note and downloaded the lecture just look back on even took notes for the shorts on week one. now what i clearly need is to be taught ...
0
votes
1answer
13 views

My blur function blurs every image, but fails every check50 check - please help!

I'd really appreciate any help that can be offered here. My code seems to output a blurred image perfectly, but fails every check50 check and I can't work out why... void blur(int height, int width, ...
0
votes
1answer
8 views

Just started games50 Game Development no environment?

What am I missing? I see he jumps into coding and gives commands in the integrated vscode terminal but never explained anything about installing packages for the environment? I tried installing Love ...
0
votes
2answers
21 views

Why Doesn't fwrite overwrite previously copied data?

I'm beginning to wrap my head around the week 4 problem set, and I'm confused about how the fread and fwrite functions work. As I understand it, fread tells the computer to copy data into RAM, and ...
0
votes
0answers
6 views

Gradebook does not update after pset submission

I am currently on Week4, but my grade book seems not updating since 2 days ago, after I have submitted pset4 - Filter (More). I have just submitted pset4 - Recover, tho problem sets have shown in my ...
0
votes
1answer
26 views

pset4 - Recover passed check50, but want to understand the logic on fwrite or file-pointer

Below are my code for pset4 - Recover, it passed the check50, but I am trying to understand the logic on a particular process of fwrite or file-pointer. In short, my question is how does line 74 know ...
0
votes
1answer
20 views

How to submit Pest1 with SUBMIT50?

When I try to submit Pset1, in the terminal, it always does this: submit50 cs50/problems/2020/x/mario/less Connecting...... Authenticating..... GitHub username: A***********8144 GitHub password: ******...
0
votes
2answers
20 views

A problem with my code in PSET 1 Mario less comfortable

I think I have got everything right except when my program is run it prints an extra line without any hashes, can anybody point out or correct my arithmetic (or the code)? Here's the code: #include<...
0
votes
1answer
15 views

Why is my get_positive_int code not working? (I seem to do everything right!)

Here's my code (written in C), I was trying to program this for a long time, and even when I just tried to copy the code directly from the video lecture, it's wrong! Please help me. Here's my code: #...
0
votes
1answer
24 views

Need Help with using malloc and PSET4 Recover

I cannot tell what's wrong with my code. When using check50 I keep getting the results below: :) recover.c exists. :) recover.c compiles. :) handles lack of forensic image :( recovers 000.jpg ...
0
votes
1answer
16 views

pset 3 caesar - output looks fine but check50 returns errors

PS2 caesar to output ciphertext works fine, and outputs all texts as expected - however check50 returns poor score. //Code is: #include <stdio.h> #include <cs50.h> #include <string.h>...
0
votes
1answer
19 views

Receiving EOF when I execute check50 (Readability)

I keep getting EOF when I check50, but my program runs fine. It gives the correct output for every text input. I can not find a solution here. It looks fine, but when I run the check50 command I get ...
0
votes
2answers
16 views

Runoff Help: Tabulate Handles Multiple Rounds of Preferences

I cannot figure out why I am getting rejected on check50 for ":( tabulate handles multiple rounds of preferences - tabulate function did not produce correct vote totals". I get green ...

15 30 50 per page
1
2 3 4 5
248