For Example I have this string
$string = "HelloWorld";
And I want to check if the first four letters is equal to "Hell"
if($string[0]=="H"&&$string[1]=="e"&&$string[2]=="l"&&$string[3]=="l");
Is there a better or simplified way of checking this? maybe $string[0-4] or something like that