Initial data commit
This commit is contained in:
parent
72d218235f
commit
f23f22d71c
199087 changed files with 3378941 additions and 0 deletions
15
Task/Substring/Yabasic/substring.basic
Normal file
15
Task/Substring/Yabasic/substring.basic
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
c$ = "abcdefghijklmnopqrstuvwxyz"
|
||||
n = 12
|
||||
m = 5
|
||||
// starting from n characters in and of m length;
|
||||
print mid$(c$, n, m)
|
||||
// starting from n characters in, up to the end of the string;
|
||||
print mid$(c$, n)
|
||||
// whole string minus last character;
|
||||
print left$(c$, len(c$) - 1)
|
||||
// starting from a known character within the string and of m length;
|
||||
print mid$(c$, instr(c$, "b"), m)
|
||||
// starting from a known substring within the string and of m length.
|
||||
f$ = "pq"
|
||||
print mid$(c$, instr(c$, f$), m)
|
||||
end
|
||||
Loading…
Add table
Add a link
Reference in a new issue