Решить . написать код. если в заданную строку символов входит каждая из букв слова key, тогда напечатать yes, иначе - no.
158
171
Ответы на вопрос:
Vb. dim msg as string msg = inputbox("введите строку") dim s as integer if msg.indexof("k") > -1 then s += 1 if msg.indexof("e") > -1 then s += 1 if msg.indexof("y") > -1 then s += 1 if s = 3 then msgbox("yes") else msgbox("no")pascal.program chislo; var x : integer; msg : string; begin write('введите строку: '); readln(msg); if pos(msg,'k')> 0 then x: =x+1; if pos(msg,'e')> 0 then x: =x+1; if pos(msg,'y')> 0 then x: =x+1; if (x=3) then writeln('yes') else writeln('no')end.
Популярно: Информатика
-
Bogdan8ra4yk18.06.2023 08:16
-
exm0r3d31.12.2022 16:37
-
идинахер8927.02.2022 03:04
-
MrDackes04.09.2022 08:29
-
sofa37207.10.2020 11:55
-
VasiliyLihasdb22.01.2021 13:49
-
FACE09116.03.2022 20:46
-
alena12314130.01.2021 07:20
-
NataliZotow02.07.2021 06:59
-
Hactenьka04.11.2022 00:29