Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/vitalijr2/c-pointers
https://github.com/vitalijr2/c-pointers
Last synced: 26 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/vitalijr2/c-pointers
- Owner: vitalijr2
- License: apache-2.0
- Created: 2019-08-30T18:14:28.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2019-08-31T09:00:22.000Z (about 5 years ago)
- Last Synced: 2023-08-16T17:50:36.813Z (about 1 year ago)
- Language: C++
- Size: 13.7 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# C pointers
* Simple variables
* Arrays
* Strings
* Functions: parameters are passed by value, by reference and as pointersShould print next lines
```
Hello world of C pointers!
==========================Simple variables
----------------Initial values:
a = 1
b = 1
c = 1Increment a and decrement b
a = 2
b = 0
c = 2Increment value of c
a = 3
b = 0
c = 3Arrays
------Initial values:
a = { 1 2 3 4 5 }
b = 2
c = 1Increment second element and decrement b
a = { 1 3 3 4 5 }
b = 1
c = 1Increment c
a = { 1 3 3 4 5 }
b = 1
c = 3Increment value of c
a = { 1 4 3 4 5 }
b = 1
c = 4Strings
-------Initial values:
a = "The quick brown fox jumps over the lazy dog"
b = f
c = TReplace fourth word and change b
a = "The quick brown cat jumps over the lazy dog"
b = +
c = TIncrement c
a = "The quick brown cat jumps over the lazy dog"
b = +
c = lReplace eigth word by c
a = "The quick brown cat jumps over the blue dog"
b = +
c = eFunctions
------new latin letter, total 1
new vowel, total 1
new latin letter, total 2
new consonant, total 1
new latin letter, total 3
new consonant, total 2
new latin letter, total 4
new consonant, total 3
new latin letter, total 5
new consonant, total 4
new latin letter, total 6
new vowel, total 2
new latin letter, total 7
new consonant, total 5
new latin letter, total 8
new consonant, total 6
new latin letter, total 9
new consonant, total 7Total when pass counters by value:
latin letters: 9
consonants: -1
vowels: -1new latin letter, total 1
new vowel, total 1
new latin letter, total 2
new consonant, total 1
new latin letter, total 3
new consonant, total 2
new latin letter, total 4
new consonant, total 3
new latin letter, total 5
new consonant, total 4
new latin letter, total 6
new vowel, total 2
new latin letter, total 7
new consonant, total 5
new latin letter, total 8
new consonant, total 6
new latin letter, total 9
new consonant, total 7Total when pass counters by reference:
latin letters: 9
consonants: 7
vowels: 2new latin letter, total 1
new vowel, total 1
new latin letter, total 2
new consonant, total 1
new latin letter, total 3
new consonant, total 2
new latin letter, total 4
new consonant, total 3
new latin letter, total 5
new consonant, total 4
new latin letter, total 6
new vowel, total 2
new latin letter, total 7
new consonant, total 5
new latin letter, total 8
new consonant, total 6
new latin letter, total 9
new consonant, total 7Total when pass counters by pointer:
latin letters: 9
consonants: 7
vowels: 2
```