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
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. How can I fix a number between 0 and 1 in table undex??

How can I fix a number between 0 and 1 in table undex??

Scheduled Pinned Locked Moved C / C++ / MFC
questionc++databasehelptutorial
1 Posts 1 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • Y Offline
    Y Offline
    yagami_md
    wrote on last edited by
    #1

    Hi friends I tried to define a new value between 0 and 1 , in table index , for example 0,1,2,3,4,5 is index of table of 6 value , I want insert new value between 0 and 1 for be like that new index 0,val,1,2,3,4,5

    define plus(c) (c+1)
    #define moins(c) (c)
    #define plus(val) (1)
    #define moins(val) (0)
    #define val (200)
    Int main ()
    {
    Int tab[11];
    Int moy[11];
    Int c;
    For (c=0;c<10;c++)
    {
    Tab[c]=c+1;
    }
    Tab[11]=20;
    Moy[0]=0;
    Moy[1]=tab[11];
    For(c=1;c<=11;c++)
    {
    Moy[plus(c)]=tab[c];
    }

    1 Reply Last reply
    0
    Reply
    • Reply as topic
    Log in to reply
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes


    • Login

    • Don't have an account? Register

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