if then else statement

if then else statement - Messaggi

#1 Pubblicato: 24/03/2019 15:57:17
jbv74

jbv74

0 apprezzamenti in 3 post.

Gruppo: User

Hello

I'm new in Smath

I want to do "if δ>0 then k=a+b else k=c+d"

But impossible to include the equation k:=a+b in the "if statement"

When I type "equal" after "k", the "equal" sign is put on the fist line and answer "k-not defined"

I found an exemple on the forum but I'm not able to reproduce it by myself

My test file is attached

Thank you for your help

test if statement.sm (5,23 KiB) scaricato 1162 volta(e).
#2 Pubblicato: 24/03/2019 16:47:44
sergio

sergio

127 apprezzamenti in 342 post.

Gruppo: User

you have to type ":" (colon) and not "=" (equal)

sergio
#3 Pubblicato: 24/03/2019 18:34:24
Jean Giraud

Jean Giraud

983 apprezzamenti in 6.866 post.

Gruppo: User

Wrote

Thank you for your help



if_else.PNG
#4 Pubblicato: 30/03/2019 15:52:09
jbv74

jbv74

0 apprezzamenti in 3 post.

Gruppo: User

Thanks
  • Nuovi post
  • Nessun nuovo post