SA-MP Forums Archive
Letter in string. - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Letter in string. (/showthread.php?tid=100813)



Letter in string. - Dreftas - 06.10.2009

Hot to find what letter/symbol etc. is in string ? For example:
String: ABCDE
hot to find third letter of that string, which will be C ?




Re: Letter in string. - yom - 06.10.2009

new string[] = "ABCDE";
printf("%c", string[2]);

Will print "C".


Re: Letter in string. - Dreftas - 06.10.2009

Quote:
Originally Posted by 0rb
new string[] = "ABCDE";
printf("%c", string[2]);

Will print "C".
Thx a lot