Sun. Feb 23rd, 2025
Notifications
Clear all

What is the size of the int* data type in C/C++?


Chris DuBois
Posts: 1239
Registered
Topic starter
(@chris)
Famed Member
Joined: 6 months ago

The size of an int* (pointer to int) varies based on system architecture. Why is it 4 bytes on a 32-bit system and 8 bytes on a 64-bit system? How does pointer arithmetic work in C/C++?

Share: