+ 4

C#Love Chat-6

Learnin ref and return methods Try to satisfy Mandy ;) Each answer will increase or decrease her satisfaction depends on time, when you give some answer. F.E:if you kiss Mandy first, she will be angry. But then she can change her mood ;) Can I change if(index==0||index==1........) on something shorter? index==0||1 does not work https://code.sololearn.com/cq9RMlfKULAB/?ref=app

12th Sep 2017, 7:26 AM
Топчий Анастасия Александровна
Топчий Анастасия Александровна - avatar
6 Antworten
+ 3
of course I forgot to ask a question. I what to make this code a bit shorter. Can I change if(index==0||index==1.....) on something shorter? index==0||1 does not work(
12th Sep 2017, 8:18 AM
Топчий Анастасия Александровна
Топчий Анастасия Александровна - avatar
+ 3
I have to check if index equals 0 or 4 or 5. Coding this: if(index==0 || index==4 || index == 5){}. It is a long string,and I would like it to be shorter. Is it possible? @luka можно как-то короче записать условие, или постоянно перечислять индекс придется?)
12th Sep 2017, 11:54 AM
Топчий Анастасия Александровна
Топчий Анастасия Александровна - avatar
+ 3
@luka спасибо =^_^=
12th Sep 2017, 1:42 PM
Топчий Анастасия Александровна
Топчий Анастасия Александровна - avatar
+ 2
What's the thing here?
12th Sep 2017, 7:52 AM
👑 Prometheus 🇸🇬
👑 Prometheus 🇸🇬 - avatar