0% found this document useful (0 votes)
71 views

This Is CS50

This document provides an overview of the CS50 course including information about valgrind for debugging memory leaks, structs and linked lists, and the final project requirements. It discusses tools like scanf and FILE for input/output and shows examples of functions for searching, inserting, and deleting nodes from a linked list. The document also lists additional topics to be covered later in the course.

Uploaded by

Ashvini Kumar
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
71 views

This Is CS50

This document provides an overview of the CS50 course including information about valgrind for debugging memory leaks, structs and linked lists, and the final project requirements. It discusses tools like scanf and FILE for input/output and shows examples of functions for searching, inserting, and deleting nodes from a linked list. The document also lists additional topics to be covered later in the course.

Uploaded by

Ashvini Kumar
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 16

This is CS50.

valgrind
valgrind --leak-check=full ./program

Invalid write of size 4


at 0x804840F: f (memory.c:21)
by 0x8048421: main (memory.c:26)
40 bytes in 1 blocks are definitely lost in loss record 1 of 1
at 0x4025BDC: malloc (vg_replace_malloc.c:195)
by 0x8048405: f (memory.c:20)
by 0x8048421: main (memory.c:26)

scanf

struct

FILE

http://www.justcat.co.za/store/pc-accessories-c-1.html

week 7

CS50 Lunch, Fri 1:15pm


cs50.net/rsvp

Final Project

Pre-Proposal
Proposal
Status Report
CS50 Hackathon
Implementation
CS50 Fair

arrays

typedef struct node


{
int n;
struct node* next;
}
node;

insert
delete
search
traverse

bool search(int n, node* list)


{
node* ptr = list;
while (ptr != NULL)
{
if (ptr->n == n)
{
return true;
}
ptr = ptr->next;
}
return false;
}

to be continued...

You might also like