|
Bas de page | |
---|---|
Auteur | Sujet : Aide boucle While Encore ?? je pete un cable ... :'( |
![]() Publicité | Posté le 29-10-2008 à 23:37:36 ![]() ![]() |
brisssou 8-/ |
Harkonnen ModérateurUn modo pour les bannir tous |
--------------- J'ai un string dans l'array (Paris Hilton) |
brisssou 8-/ |
LeRiton | Hints : la comparaison de String, c'est equals(), et les String java sont immutables. |
astrojojo Editeur compulsif |
J'allais le dire.
J'arrive pas à voir le rapport ? On peut très bien faire : String a = "abc"; a="def"; non? Message cité 1 fois Message édité par astrojojo le 30-10-2008 à 14:25:45 |
LeRiton |
|
astrojojo Editeur compulsif | Tu ferais quoi à la place? Je vois pas trop d'autre solution à part faire une ArrayList<String> pour ajouter une nouvelle variable à chaque tour (mais beurk aussi). |
![]() Publicité | Posté le 30-10-2008 à 14:44:52 ![]() ![]() |
LeRiton | Je chipote hein. Juste qu'à mon sens, la référence sert à rien. On veut "continuer tant que l'utilisateur tape "oui"", bin si je traduit bêtement, c'est :
Je critiquais pas le changement de référence mais son utilisation. Je chipote quoi. Edit : et non, toujours pas de rapport avec le fait que les String soient immutables. Mais c'est une info toujours intéressante Message cité 1 fois Message édité par LeRiton le 30-10-2008 à 15:06:17 |
LeRiton | |
baobab95210 | Bon pour mon exo ca marche !
|
masklinn í dag viðrar vel til loftárása |
C'est pourquoi quand j'ai un littéral à tester contre une variable je met plutôt le littéral à gauche, pas de NPE possible comme ça
Message édité par masklinn le 30-10-2008 à 21:29:07 --------------- I mean, true, a cancer will probably destroy its host organism. But what about the cells whose mutations allow them to think outside the box by throwing away the limits imposed by overbearing genetic regulations? Isn't that a good thing? |
astrojojo Editeur compulsif | C'était forcément en java l'exo ? Vous avez vu les bases de la POO ? Les notions d'instance/référence te disent quelque chose ? |
baobab95210 | non cela ne me dit rien. Et oui nous n'écrivons qu'en java et rien d'autre. Je crois que le C/C++ vient dans les années suivantes je ne suis pas sur. Personne ne vient de paris 7 ?
|
masklinn í dag viðrar vel til loftárása |
--------------- I mean, true, a cancer will probably destroy its host organism. But what about the cells whose mutations allow them to think outside the box by throwing away the limits imposed by overbearing genetic regulations? Isn't that a good thing? |
astrojojo Editeur compulsif | Oui je sais, c'est juste pour savoir s'il sait ce que fait exactement le '==' ou ce que c'est une méthode. edit:
Voilà, je trouve pas ça top de commencer comme ça Message édité par astrojojo le 30-10-2008 à 21:54:30 |
masklinn í dag viðrar vel til loftárása | baobab95210, va lire http://java.sun.com/mailers/techti [...] 822.html#2
Mais ça n'a toujours pas de rapport, dans les langages avec operator overloading "==" est toujours utilisé pour l'égalité et jamais pour l'identité
Message cité 1 fois Message édité par masklinn le 30-10-2008 à 21:56:07 --------------- I mean, true, a cancer will probably destroy its host organism. But what about the cells whose mutations allow them to think outside the box by throwing away the limits imposed by overbearing genetic regulations? Isn't that a good thing? |
baobab95210 | je viens de parcourir mon poly de TD et je n'ai pas vu marqué ca...
|
masklinn í dag viðrar vel til loftárása |
Message édité par masklinn le 30-10-2008 à 22:05:01 --------------- I mean, true, a cancer will probably destroy its host organism. But what about the cells whose mutations allow them to think outside the box by throwing away the limits imposed by overbearing genetic regulations? Isn't that a good thing? |
astrojojo Editeur compulsif |
Message cité 1 fois Message édité par astrojojo le 30-10-2008 à 22:08:00 |
masklinn í dag viðrar vel til loftárása |
--------------- I mean, true, a cancer will probably destroy its host organism. But what about the cells whose mutations allow them to think outside the box by throwing away the limits imposed by overbearing genetic regulations? Isn't that a good thing? |
astrojojo Editeur compulsif |
|
masklinn í dag viðrar vel til loftárása |
Message cité 1 fois Message édité par masklinn le 30-10-2008 à 22:09:55 --------------- I mean, true, a cancer will probably destroy its host organism. But what about the cells whose mutations allow them to think outside the box by throwing away the limits imposed by overbearing genetic regulations? Isn't that a good thing? |
astrojojo Editeur compulsif |
|
masklinn í dag viðrar vel til loftárása |
--------------- I mean, true, a cancer will probably destroy its host organism. But what about the cells whose mutations allow them to think outside the box by throwing away the limits imposed by overbearing genetic regulations? Isn't that a good thing? |
![]() Publicité | Posté le ![]() ![]() |