Hallo,
ich habe ein Problem mit der Replace-Funktion. Ich habe z.B. die Buchstaben A bis E, nun will ich diese ersetzt haben. Zum Beispiel A = 1, B = 2, C = 3, D = 4. Wenn ich nun als Input "A" eingebe bekomme ich als Output irgendwie "1AAA", wodran liegt das? Was hab ich falsch gemacht, hier ist der Code:
Ich habe es auch schon so versucht indem ich die + mit & ersetzt hatte aber es kam immer das selbe raus:
Wodran liegt das? Ich hab hier nicht nur die 5, es sind über 30
ich habe ein Problem mit der Replace-Funktion. Ich habe z.B. die Buchstaben A bis E, nun will ich diese ersetzt haben. Zum Beispiel A = 1, B = 2, C = 3, D = 4. Wenn ich nun als Input "A" eingebe bekomme ich als Output irgendwie "1AAA", wodran liegt das? Was hab ich falsch gemacht, hier ist der Code:
Ich habe es auch schon so versucht indem ich die + mit & ersetzt hatte aber es kam immer das selbe raus:
1AAAA
Wodran liegt das? Ich hab hier nicht nur die 5, es sind über 30
Dieser Beitrag wurde bereits 1 mal editiert, zuletzt von „dussl“ ()