Skip to main content

Pointer and arrays in c programming

 You have probably heard this key word pointer and array if you have been writing code for C programming or might have even heard it somewhere else from other programming languages like java and C++ and javascript but what exactly are they ? 

A pointer is a variable which contains memory address


Types and memory

Every time you declare a variable, the computer will reserve memory for this variable. The memory reserved will then store the value of the variable.
Depending on the type of the variable, the computer will reserve more or less memory. The size of each type is generally defined in bytes (1 byte = 8 bits, each bit being 0 or 1). The sizes of the types also depend on the computer you are using. Here are the sizes of the most common types on most 64-bit Linux machines:

  • char -> 1 byte
  • int -> 4 bytes
  • float -> 4 bytes

To determine the size of those types on your computer, you can use the sizeof operator.

Comments

Popular posts from this blog

Privacy Policy for Calculator Plus

Effective Date: August 1, 2024 Calculator Plus developer is committed to protecting your privacy. This Privacy Policy outlines how the app collect, use, and safeguard your information when you use Calculator Plus. By using the App, you agree to the terms and conditions of this Privacy Policy. 1. Information We Collect We do not collect any personal information directly from users of the Calculator Plus app. The App is designed to function without requiring you to provide personal data. 2. Permissions Calculator Plus may request certain permissions on your device to provide a seamless experience. These permissions include:- Internet Access - For updating the app and accessing in-app content. Network State - To check the network status and provide optimal performance. We do not access or store any personal data through these permissions. 3. How We Use Information Since we do not collect any personal information, there is no data to use, share, or disclose. 4. Third-Party Services Calcula...

GB privacy policy

 Privacy Policy  This Privacy Policy applies to all apps (Android & IOS) under the Maru Developers. We has created this Policy to explain our privacy practices so you can understand what information about you is collected, used and disclosed. We collect information from you in order to provide corresponding service and better user experience. With your consent of this Privacy Policy, your usage, statistics, input while using our apps would be collected. INFORMATION WE COLLECT Generally. We may collect personal information from our users in order to provide you with a personalized, useful and efficient experience. The categories of information we collect can include: Social network's personal information and device's gallery pictures. Non-personal identification. We may collect non-personal identification information about installed applications, application usage information and device information. The information you give us, for example, when you give us your opinions to...

Football Scoreboard Live Tv Privacy Policy

  Privacy Policy for Football Scoreboard Live TV Effective Date: 1st August 2023 Welcome to our Football Application! Your privacy is important to us, and we are committed to protecting your personal information. This Privacy Policy outlines how we collect, use, and safeguard your data while you use our application. 1. Information We Collect:    - Device Information: We automatically collect information about your device, including the device type, operating system, and unique identifiers.    - Usage Data: We may gather data about how you use our app, such as the pages you visit, features accessed 2. Use of Information:    - Personalization: We use the collected data to personalize your experience within the app, provide relevant content, and enhance user     - Analytics: The collected data helps us analyze app usage patterns, identify areas for improvement, and optimize the overall user experience. 3. Data Sharing and Disclosure:  ...