[ create a new paste ] login | about

Link: http://codepad.org/8KbwMq36    [ raw code | output | fork ]

PHP, pasted on Oct 23:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
<?php
    $str1 = "OneTwoThreeFourFiveSixSeven";
    $str2 = "OneThreeFourSevenFiveSix";
    if(strrpos($str1, "Two") ){
        echo 'Two is in $str1\n';
    }else{
        echo 'Two is not in $str1\n';
    }

    if(strrpos($str2, "Two") ){
        echo 'Two is in $str2\n';
    }else{
        echo 'Two is not in $str2\n';
    }
?>


Output:
1
Two is in $str1\nTwo is not in $str2\n


Create a new paste based on this one


Comments: