1

Est-il possible de faire un tableau de chaines de caratctères?hum
Vive le coding gba.
www.codegba.fr.st

2

Oui rotfl

3

grin
ben comment on fait?
pasrcequ'en plus les chaines de caractères sont déjà des tableaux alos ça mélange un peu les pinceaux...
confus
Vive le coding gba.
www.codegba.fr.st

4

ben, un tableau de tableau.
Autrement dit, une matrice
avatar
Tutorial C (TI-89/92+/v200) - Articles Développement Web (PHP, Javascript, ...)
« What is the sound of Perl? Is it not the sound of a wall that people have stopped banging their heads against? » - Larry Wall

5

char **pTableau; smile
ou
char *pChaine[n];
ou
char pChaine[n][n];

En gros.

6

tsss
Justement je déclare un tableau: de 2cdc de 3 caractères chacun

char tab[2][3];

et la je ne sais pas comment faire pour inscrire la première dans tab. J'ai essayé:

tab[0][0]="abc";

mais ça donne un warning "assignement makes integer from pointer without a cast"

confus
Vive le coding gba.
www.codegba.fr.st

7

pr copier des chaines de caractères, il faut utiliser strcpy, et non '=' !!!

quelque chose du style :
strcpy(tab[0], "abc")
avatar
Tutorial C (TI-89/92+/v200) - Articles Développement Web (PHP, Javascript, ...)
« What is the sound of Perl? Is it not the sound of a wall that people have stopped banging their heads against? » - Larry Wall

8

merci ça marche winkwink
Vive le coding gba.
www.codegba.fr.st

9

de rine.
avatar
Tutorial C (TI-89/92+/v200) - Articles Développement Web (PHP, Javascript, ...)
« What is the sound of Perl? Is it not the sound of a wall that people have stopped banging their heads against? » - Larry Wall

10

D'ailleurs, tab[2][3] ne suffit pas pour pouvoir faire strcpy(tab[0], "abc") (essaye de copier quelque chose dans tab[1], puis de lire tab[0] pour t'en apercevoir). Il faut au minimum tab[2][4] (pour pouvoir mettre le 0 final).
avatar
Mes news pour calculatrices TI: Ti-Gen
Mes projets PC pour calculatrices TI: TIGCC, CalcForge (CalcForgeLP, Emu-TIGCC)
Mes chans IRC: #tigcc et #inspired sur irc.freequest.net (UTF-8)

Liberté, Égalité, Fraternité

11

char *formidable[]={"str1","string n°2","ouais","formidable"};soccer
avatar
fabetal_ > Hier, je me suis fait monter par un pote
redangel > et en chevals, ça donne quoi?
Nil> OMG I think I'm gay