Author Topic: Chaine et variables (string and variable) [English/French]  (Read 3952 times)

0 Members and 1 Guest are viewing this topic.

Offline Kiligolo

  • LV5 Advanced (Next: 300)
  • *****
  • Posts: 218
  • Rating: +10/-1
    • View Profile
Chaine et variables (string and variable) [English/French]
« on: October 22, 2010, 02:44:54 pm »
Bonjour,

Je suis en train de programmer et je ne sais pas comment "transformer" (ou mettre) une variable dans une chaine. ???
Quelqu'un pourrais me dire comment on fait, merci d'avance!  :)

Hello,

I am programming and I do not know how to save a variable in a string. ???
Somebody could me say how to do, thanks! :)
Spoiler For Calcul Mental:
Version 1.3 :100%!!
Here is a program that reduces your dependence on the calculator! Click here!
Spoiler For Some screen shots:
       
The screenshots are in french but there is an english version

Offline Munchor

  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 6199
  • Rating: +295/-121
  • Code Recycler
    • View Profile
Re: Chaine et variables (string and variable) [English/French]
« Reply #1 on: October 22, 2010, 02:50:51 pm »
transformer une variable dans une chaine?

Une variable qu'est'un numero pour un chaine?

Offline Kiligolo

  • LV5 Advanced (Next: 300)
  • *****
  • Posts: 218
  • Rating: +10/-1
    • View Profile
Re: Chaine et variables (string and variable) [English/French]
« Reply #2 on: October 22, 2010, 03:13:21 pm »
J'aimerais enregistrer une variable (A par exemple) dans une chaine (Str1 par exemple). Mais je ne connais que la fonction expr( qui fait l'inverse :( . Je ne sais pas si c'est possible mais je me rappelle avoir fait ceci...

I would like to save a variable (A for example) in a string (Str1 for example). But I know only the function expr( which does unlike :( . I do not know if it is possible but I remember doing this...
Spoiler For Calcul Mental:
Version 1.3 :100%!!
Here is a program that reduces your dependence on the calculator! Click here!
Spoiler For Some screen shots:
       
The screenshots are in french but there is an english version

Offline Munchor

  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 6199
  • Rating: +295/-121
  • Code Recycler
    • View Profile
Re: Chaine et variables (string and variable) [English/French]
« Reply #3 on: October 22, 2010, 03:19:27 pm »
Si tu veux declarer une chaine fais comme ça:

Code: [Select]
"Salut, monde!" (STO->) str1

----------------------------OU----------------------

Input "", str2
Disp str2

Mais je ne comprehends pas ce que tu dis trés bien :S

Offline Kiligolo

  • LV5 Advanced (Next: 300)
  • *****
  • Posts: 218
  • Rating: +10/-1
    • View Profile
Re: Chaine et variables (string and variable) [English/French]
« Reply #4 on: October 22, 2010, 03:30:58 pm »
Oh ok. ;D
Je crois que je ne me suis pas très bien exprimé...
Bon j'ai ceci comme code:
Code: [Select]
Input A
...
//Et là je voudrais faire une chose comme A->Str0 mais ERR:DATA TYPE...

Oh ok. ;D
I think I am not very well expressed...
So here is the program:

Code: [Select]
Input A
...
//Here, I would like to do something like A->Str0 but ERR:DATA TYPE...
Spoiler For Calcul Mental:
Version 1.3 :100%!!
Here is a program that reduces your dependence on the calculator! Click here!
Spoiler For Some screen shots:
       
The screenshots are in french but there is an english version

Offline Munchor

  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 6199
  • Rating: +295/-121
  • Code Recycler
    • View Profile
Re: Chaine et variables (string and variable) [English/French]
« Reply #5 on: October 22, 2010, 03:36:30 pm »
Tu dois faire:

Code: [Select]
Input "", A
// Pour utiliser chaines

Code: [Select]
Input A
//Pour utiliser numeros

Offline Kiligolo

  • LV5 Advanced (Next: 300)
  • *****
  • Posts: 218
  • Rating: +10/-1
    • View Profile
Re: Chaine et variables (string and variable) [English/French]
« Reply #6 on: October 22, 2010, 03:44:28 pm »
I would like to change a number into a string.
I know the input fonction. The code:
Code: [Select]
Input "NUMERATEUR:",A
Input "DENOMINATEUR:",B
Output(5,1,"CALCUL
lcm(A,B->C
//Here, I want to change the variable A into Str0
//The same with B and C
I am French so my English it a bit bad. ;D
Spoiler For Calcul Mental:
Version 1.3 :100%!!
Here is a program that reduces your dependence on the calculator! Click here!
Spoiler For Some screen shots:
       
The screenshots are in french but there is an english version

Offline Munchor

  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 6199
  • Rating: +295/-121
  • Code Recycler
    • View Profile
Re: Chaine et variables (string and variable) [English/French]
« Reply #7 on: October 22, 2010, 03:51:51 pm »
oooh, transformer un numero pour une chaine:

Code: [Select]
:{0,1→L₁
:{0,N→L₂
:LinReg(ax+b) Y₁
:Equ►String(Y₁,Str1
:sub(Str1,1,length(Str1)-3→Str1

Offline Kiligolo

  • LV5 Advanced (Next: 300)
  • *****
  • Posts: 218
  • Rating: +10/-1
    • View Profile
Re: Chaine et variables (string and variable) [English/French]
« Reply #8 on: October 23, 2010, 02:47:46 pm »
Are you sure? The calculator say ERR:DIM MISMATCH on "linReg(ax+b) Y1"... :(
Spoiler For Calcul Mental:
Version 1.3 :100%!!
Here is a program that reduces your dependence on the calculator! Click here!
Spoiler For Some screen shots:
       
The screenshots are in french but there is an english version

Offline Kiligolo

  • LV5 Advanced (Next: 300)
  • *****
  • Posts: 218
  • Rating: +10/-1
    • View Profile
Re: Chaine et variables (string and variable) [English/French]
« Reply #9 on: October 24, 2010, 07:47:50 am »
Personne pour m'aider ? :'(

Nobody is here to help me? :'(
« Last Edit: October 24, 2010, 07:53:20 am by Kiligolo »
Spoiler For Calcul Mental:
Version 1.3 :100%!!
Here is a program that reduces your dependence on the calculator! Click here!
Spoiler For Some screen shots:
       
The screenshots are in french but there is an english version

Offline Runer112

  • Moderator
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2289
  • Rating: +639/-31
    • View Profile
Re: Chaine et variables (string and variable) [English/French]
« Reply #10 on: October 24, 2010, 07:59:03 am »
oooh, transformer un numero pour une chaine:

Code: [Select]
:{0,1→L₁
:{0,N→L₂
:LinReg(ax+b) Y₁
:Equ►String(Y₁,Str1
:sub(Str1,1,length(Str1)-3→Str1

This is indeed the way to convert a number into a string, and this code should work. Are you sure you entered it correctly?

Offline Kiligolo

  • LV5 Advanced (Next: 300)
  • *****
  • Posts: 218
  • Rating: +10/-1
    • View Profile
Re: Chaine et variables (string and variable) [English/French]
« Reply #11 on: October 24, 2010, 08:08:19 am »
It works!
Think you for your help! :D
Spoiler For Calcul Mental:
Version 1.3 :100%!!
Here is a program that reduces your dependence on the calculator! Click here!
Spoiler For Some screen shots:
       
The screenshots are in french but there is an english version

Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55943
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: Chaine et variables (string and variable) [English/French]
« Reply #12 on: October 24, 2010, 08:25:01 pm »
Désolé j'aimerais bien aider mais malheureusement je ne suis pas très connaisseur en Axe et ayant quitté temporairement la programmation TI ça ne m'aide pas beaucoup :(

Offline Munchor

  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 6199
  • Rating: +295/-121
  • Code Recycler
    • View Profile
Re: Chaine et variables (string and variable) [English/French]
« Reply #13 on: October 25, 2010, 07:33:59 am »
oooh, transformer un numero pour une chaine:

Code: [Select]
:{0,1→L₁
:{0,N→L₂
:LinReg(ax+b) Y₁
:Equ►String(Y₁,Str1
:sub(Str1,1,length(Str1)-3→Str1

This is indeed the way to convert a number into a string, and this code should work. Are you sure you entered it correctly?

Yeah, this works very well for me too, but I see he already got it :)