Memory

From this lecture onwards the cs50.h library is not going to be used anymore!

Binary system : 0 & 1

Hexa system: 0123456789ABCDEF (numbers 0-15)

Snippet of memory:
Attachments/Pasted image 20260615190639.png
IN computer the memory location are referred in Hexadecimal. So per convention, any number using Hexadecimal notation has a 0x.

Code starting from addresses.c
#include <stdio.h>
#include <cs50.h>
int main(void)
{
	int n = 50;
	printf("%i\n",n);
}

New terminology:

#include <stdio.h>
#include <cs50.h>
int main(void)
{
	int n = 50;
	printf("%p\n",&n);
}
Pointers:

Core topic in C! A pointer is a variable that can store in address

Powered by Forestry.md