i[3] or 3[i] i [3] alebo 3 [i]
Last night a while writing a very basic program in 'C' language, I came across something weird. Posledná noc chvíli písania veľmi základné program v 'C' jazyk, som sa stretol niečo divné. Basically in 'C' if you want to display the value of some element in an array it is denoted as i [no. V podstate v 'C', ak chcete zobrazovať hodnoty niektorých prvkov v poli je označený ako aj [no. of index], where 'i' is name of the array and in square bracket you write the index number, which u want to display. index], kde 'i' je názov poľa a hranatá zátvorka píšete indexové číslo, u ktorej chcete zobraziť.
The mistake I made was I wrote the index_number[name of array] ( Wrote 3[i] instead of i[3] ) and it gave the same result as it should have given, if I had written it correctly. Urobil som chybu, bol som napísal index_number [názov poľa] (Napísal / a 3 [i] miesto i [3]) a dal ho k rovnakému výsledku ako by boli, keby som mal písomného správne. Check the screenshot shown below. Pozrite sa na snímku uvedený nižšie.
Code: Kód:

Output Výstup

Now I m wondering how does that happen, I mean whatever I have read about 'C' programming as yet, says i[3] is the method to access the element at 3rd index, in fact I have not ever came across any notation of the form 3[i], so what's the issue, have you ever seen this, why does this happen, any idea? Teď jsem zvědav, jak to m, aby sa to stalo, myslím čokoľvek som si prečítal asi 'C' programovania zatiaľ hovorí, i [3] je spôsob prístupu k prvku na 3. register, v skutočnosti som nemala vôbec žiadne prišlo cez notáciu formulár 3 [i], tak to, čo je problém, už si niekedy videl to, prečo sa to stalo, každý nápad?
If you want to download this code and see it yourself, Ak si chcete stiahnuť tento kód a uvidíte sami, here is the file Tu je obrázok , we have uploaded it for you. Sme nahrali to pre vás.
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |

Posted on 9th April 2008 by Publikované dňa 9. apríla 2008 do Manav Mishra Manav Mishra , here to write articles about things which are somehow related to computers, internet (and at times, may be, to blogging as well). , Tu písať články o veciach, ktoré sú nejakým spôsobom spojené s počítačmi, internet (a niekedy môže byť pre blogovanie rovnako). He wants to make an Identity for himself, he loves, testing new softwares and services which can really help to improve the productivity of individual. All posts by Chce vytvoriť identitu pre seba, miluje, testovanie nového softvér a služby, ktoré môžu skutočne pomôcť zlepšiť produktivitu jednotlivca. Všetky príspevky Manav Mishra Manav Mishra | Connect with me @ | Spojte sa so mnou @ Twitter Cvrlikání | | Stumble Klopýtnutí | Need more help? | Potrebujete ďalšiu pomoc? Ask your Questions at our Opýtajte sa na vaše otázky na naše Support Center Centrum pomoci




























Free Email Subscription
Leave your response! Zanechajte Vašu odpoveď!