Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
U

User 11395775

@User 11395775
About
Posts
1
Topics
1
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • Pointer address variation in c
    U User 11395775

    I do not understand why is the pointer address changing everytime during the output for a code while I am executing the same code? The code:

    int main()
    {
    int a;
    a=100;
    int *b;
    b= &a;
    printf("The address of a is %p\n", b);

    return 0;
    }

    The gcc compiler output:

    nikhil@nikhil-Lenovo-Product:~/Desktop$ ./a.out
    The address of a is 0x7fff990d2f24
    nikhil@nikhil-Lenovo-Product:~/Desktop$ ./a.out
    The address of a is 0x7fffcec94eb4
    nikhil@nikhil-Lenovo-Product:~/Desktop$ ./a.out
    The address of a is 0x7fff70b595e4
    nikhil@nikhil-Lenovo-Product:~/Desktop$

    C / C++ / MFC question
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups