1--TEST-- 2strcasecmp() function 3--INI-- 4precision = 12 5--FILE-- 6<?php 7/* Compares two strings in case-insensitive manner */ 8 9echo "#### Basic and Possible operations ####"; 10/* creating an array of strings to be compared */ 11$arrays = array( 12 array("a", 'A', chr(128), chr(255), chr(256)), 13 array("acc", "Acc", 'aC', "acCc", 'acd', "?acc", 'Acc!', "$!acc", ";acc"), 14 array("1", "0", 0, "-1", -1, NULL, null, "", TRUE, true, FALSE, "string"), 15 array(10.5, 1.5, 9.5, 11.5, 100.5, 10.5E1, -10.5, 10, 0.5) 16 ); 17 18/* loop through to go each and every element in an array 19 and comparing the elements with one and other */ 20foreach($arrays as $str1_arr){ 21 echo "\n*** comparing the strings in an \n"; 22 print_r($str1_arr); 23 for ($i=0; $i<count($str1_arr); $i++){ 24 echo "\nIteration $i\n"; 25 for($j=0; $j<count($str1_arr); $j++){ 26 echo "- strcasecmp of '$str1_arr[$i]' and '$str1_arr[$j]' is => "; 27 var_dump(strcasecmp($str1_arr[$i], $str1_arr[$j])); 28 } 29 } 30} 31 32 33 34echo "\n#### Testing Miscelleneous inputs ####\n"; 35 36echo "--- Testing objects ---\n"; 37/* we get "Recoverable fatal error: saying Object of class could not be converted 38 to string" by default when an object is passed instead of string. 39The error can be avoided by choosing the __toString magix method as follows: */ 40 41class string1 { 42 function __toString() { 43 return "Hello, world"; 44 } 45} 46$obj_string1 = new string1; 47 48class string2 { 49 function __toString() { 50 return "hello, world\0"; 51 } 52} 53$obj_string2 = new string2; 54 55var_dump(strcasecmp("$obj_string1", "$obj_string2")); 56 57 58echo "\n--- Testing arrays ---\n"; 59$str_arr = array("hello", "?world", "!$%**()%**[][[[&@#~!"); 60var_dump(strcasecmp("hello?world,!$%**()%**[][[[&@#~!", $str_arr)); 61var_dump(strcasecmp("hello?world,!$%**()%**[][[[&@#~!", "$str_arr[1]")); 62var_dump(strcasecmp("hello?world,!$%**()%**[][[[&@#~!", "$str_arr[2]")); 63 64 65echo "\n--- Testing a longer and heredoc string ---\n"; 66$string = <<<EOD 67abcdefghijklmnopqrstuvwxyz0123456789abcdefghijklmnopqrstuvwxyz0123456789 68abcdefghijklmnopqrstuvwxyz0123456789abcdefghijklmnopqrstuvwxyz0123456789 69abcdefghijklmnopqrstuvwxyz0123456789abcdefghijklmnopqrstuvwxyz0123456789 70abcdefghijklmnopqrstuvwxyz0123456789abcdefghijklmnopqrstuvwxyz0123456789 71abcdefghijklmnopqrstuvwxyz0123456789abcdefghijklmnopqrstuvwxyz0123456789 72abcdefghijklmnopqrstuvwxyz0123456789abcdefghijklmnopqrstuvwxyz0123456789 73abcdefghijklmnopqrstuvwxyz0123456789abcdefghijklmnopqrstuvwxyz0123456789 74@#$%^&**&^%$#@!~:())))((((&&&**%$###@@@!!!~~~~@###$%^&* 75abcdefghijklmnopqrstuvwxyz0123456789abcdefghijklmnopqrstuvwxyz0123456789 76EOD; 77var_dump(strcasecmp($string, $string)); 78var_dump(strcasecmp($string, "xyz0123456789")); 79var_dump(strcasecmp($string, "&&&")); 80 81echo "\n--- Testing a heredoc null string ---\n"; 82$str = <<<EOD 83EOD; 84var_dump(strcasecmp($str, "\0")); 85var_dump(strcasecmp($str, NULL)); 86var_dump(strcasecmp($str, "0")); 87 88 89echo "\n--- Testing simple and complex syntax strings ---\n"; 90$str = 'world'; 91 92/* Simple syntax */ 93var_dump(strcasecmp("Hello, world", "$str")); 94var_dump(strcasecmp("Hello, world'S", "$str'S")); 95var_dump(strcasecmp("Hello, worldS", "$strS")); 96 97/* String with curly braces, complex syntax */ 98var_dump(strcasecmp("Hello, worldS", "${str}S")); 99var_dump(strcasecmp("Hello, worldS", "{$str}S")); 100 101echo "\n--- Testing binary safe and binary chars ---\n"; 102var_dump(strcasecmp("Hello\0world", "Hello")); 103var_dump(strcasecmp("Hello\0world", "Helloworld")); 104var_dump(strcasecmp("\x0", "\0")); 105var_dump(strcasecmp("\000", "\0")); 106var_dump(strcasecmp("\x00", "")); 107var_dump(strcasecmp("\x00", NULL)); 108var_dump(strcasecmp("\000", NULL)); 109 110echo "\n--- Comparing long float values ---\n"; 111/* Here two different outputs, which depends on the rounding value 112 before converting to string. Here Precision = 12 */ 113var_dump(strcasecmp(10.55555555555555555555555555, 10.5555555556)); // int(0) 114var_dump(strcasecmp(10.55555555555555555555555555, 10.555555556)); // int(-1) 115var_dump(strcasecmp(10.55555555595555555555555555, 10.555555556)); // int(0) 116 117echo "\n#### checking error conditions ####"; 118strcasecmp(); 119strcasecmp(""); 120strcasecmp("HI"); 121strcasecmp("Hi", "Hello", "World"); 122 123echo "Done\n"; 124?> 125--EXPECTF-- 126#### Basic and Possible operations #### 127*** comparing the strings in an 128Array 129( 130 [0] => a 131 [1] => A 132 [2] => � 133 [3] => � 134 [4] => 135) 136 137Iteration 0 138- strcasecmp of 'a' and 'a' is => int(0) 139- strcasecmp of 'a' and 'A' is => int(0) 140- strcasecmp of 'a' and '�' is => int(-%d) 141- strcasecmp of 'a' and '�' is => int(-%d) 142- strcasecmp of 'a' and '' is => int(%d) 143 144Iteration 1 145- strcasecmp of 'A' and 'a' is => int(0) 146- strcasecmp of 'A' and 'A' is => int(0) 147- strcasecmp of 'A' and '�' is => int(-%d) 148- strcasecmp of 'A' and '�' is => int(-%d) 149- strcasecmp of 'A' and '' is => int(%d) 150 151Iteration 2 152- strcasecmp of '�' and 'a' is => int(%d) 153- strcasecmp of '�' and 'A' is => int(%d) 154- strcasecmp of '�' and '�' is => int(0) 155- strcasecmp of '�' and '�' is => int(-%d) 156- strcasecmp of '�' and '' is => int(%d) 157 158Iteration 3 159- strcasecmp of '�' and 'a' is => int(%d) 160- strcasecmp of '�' and 'A' is => int(%d) 161- strcasecmp of '�' and '�' is => int(%d) 162- strcasecmp of '�' and '�' is => int(0) 163- strcasecmp of '�' and '' is => int(%d) 164 165Iteration 4 166- strcasecmp of '' and 'a' is => int(-%d) 167- strcasecmp of '' and 'A' is => int(-%d) 168- strcasecmp of '' and '�' is => int(-%d) 169- strcasecmp of '' and '�' is => int(-%d) 170- strcasecmp of '' and '' is => int(0) 171 172*** comparing the strings in an 173Array 174( 175 [0] => acc 176 [1] => Acc 177 [2] => aC 178 [3] => acCc 179 [4] => acd 180 [5] => ?acc 181 [6] => Acc! 182 [7] => $!acc 183 [8] => ;acc 184) 185 186Iteration 0 187- strcasecmp of 'acc' and 'acc' is => int(0) 188- strcasecmp of 'acc' and 'Acc' is => int(0) 189- strcasecmp of 'acc' and 'aC' is => int(%d) 190- strcasecmp of 'acc' and 'acCc' is => int(-%d) 191- strcasecmp of 'acc' and 'acd' is => int(-%d) 192- strcasecmp of 'acc' and '?acc' is => int(%d) 193- strcasecmp of 'acc' and 'Acc!' is => int(-%d) 194- strcasecmp of 'acc' and '$!acc' is => int(%d) 195- strcasecmp of 'acc' and ';acc' is => int(%d) 196 197Iteration 1 198- strcasecmp of 'Acc' and 'acc' is => int(0) 199- strcasecmp of 'Acc' and 'Acc' is => int(0) 200- strcasecmp of 'Acc' and 'aC' is => int(%d) 201- strcasecmp of 'Acc' and 'acCc' is => int(-%d) 202- strcasecmp of 'Acc' and 'acd' is => int(-%d) 203- strcasecmp of 'Acc' and '?acc' is => int(%d) 204- strcasecmp of 'Acc' and 'Acc!' is => int(-%d) 205- strcasecmp of 'Acc' and '$!acc' is => int(%d) 206- strcasecmp of 'Acc' and ';acc' is => int(%d) 207 208Iteration 2 209- strcasecmp of 'aC' and 'acc' is => int(-%d) 210- strcasecmp of 'aC' and 'Acc' is => int(-%d) 211- strcasecmp of 'aC' and 'aC' is => int(0) 212- strcasecmp of 'aC' and 'acCc' is => int(-%d) 213- strcasecmp of 'aC' and 'acd' is => int(-%d) 214- strcasecmp of 'aC' and '?acc' is => int(%d) 215- strcasecmp of 'aC' and 'Acc!' is => int(-%d) 216- strcasecmp of 'aC' and '$!acc' is => int(%d) 217- strcasecmp of 'aC' and ';acc' is => int(%d) 218 219Iteration 3 220- strcasecmp of 'acCc' and 'acc' is => int(%d) 221- strcasecmp of 'acCc' and 'Acc' is => int(%d) 222- strcasecmp of 'acCc' and 'aC' is => int(%d) 223- strcasecmp of 'acCc' and 'acCc' is => int(0) 224- strcasecmp of 'acCc' and 'acd' is => int(-%d) 225- strcasecmp of 'acCc' and '?acc' is => int(%d) 226- strcasecmp of 'acCc' and 'Acc!' is => int(%d) 227- strcasecmp of 'acCc' and '$!acc' is => int(%d) 228- strcasecmp of 'acCc' and ';acc' is => int(%d) 229 230Iteration 4 231- strcasecmp of 'acd' and 'acc' is => int(%d) 232- strcasecmp of 'acd' and 'Acc' is => int(%d) 233- strcasecmp of 'acd' and 'aC' is => int(%d) 234- strcasecmp of 'acd' and 'acCc' is => int(%d) 235- strcasecmp of 'acd' and 'acd' is => int(0) 236- strcasecmp of 'acd' and '?acc' is => int(%d) 237- strcasecmp of 'acd' and 'Acc!' is => int(%d) 238- strcasecmp of 'acd' and '$!acc' is => int(%d) 239- strcasecmp of 'acd' and ';acc' is => int(%d) 240 241Iteration 5 242- strcasecmp of '?acc' and 'acc' is => int(-%d) 243- strcasecmp of '?acc' and 'Acc' is => int(-%d) 244- strcasecmp of '?acc' and 'aC' is => int(-%d) 245- strcasecmp of '?acc' and 'acCc' is => int(-%d) 246- strcasecmp of '?acc' and 'acd' is => int(-%d) 247- strcasecmp of '?acc' and '?acc' is => int(0) 248- strcasecmp of '?acc' and 'Acc!' is => int(-%d) 249- strcasecmp of '?acc' and '$!acc' is => int(%d) 250- strcasecmp of '?acc' and ';acc' is => int(%d) 251 252Iteration 6 253- strcasecmp of 'Acc!' and 'acc' is => int(%d) 254- strcasecmp of 'Acc!' and 'Acc' is => int(%d) 255- strcasecmp of 'Acc!' and 'aC' is => int(%d) 256- strcasecmp of 'Acc!' and 'acCc' is => int(-%d) 257- strcasecmp of 'Acc!' and 'acd' is => int(-%d) 258- strcasecmp of 'Acc!' and '?acc' is => int(%d) 259- strcasecmp of 'Acc!' and 'Acc!' is => int(0) 260- strcasecmp of 'Acc!' and '$!acc' is => int(%d) 261- strcasecmp of 'Acc!' and ';acc' is => int(%d) 262 263Iteration 7 264- strcasecmp of '$!acc' and 'acc' is => int(-%d) 265- strcasecmp of '$!acc' and 'Acc' is => int(-%d) 266- strcasecmp of '$!acc' and 'aC' is => int(-%d) 267- strcasecmp of '$!acc' and 'acCc' is => int(-%d) 268- strcasecmp of '$!acc' and 'acd' is => int(-%d) 269- strcasecmp of '$!acc' and '?acc' is => int(-%d) 270- strcasecmp of '$!acc' and 'Acc!' is => int(-%d) 271- strcasecmp of '$!acc' and '$!acc' is => int(0) 272- strcasecmp of '$!acc' and ';acc' is => int(-%d) 273 274Iteration 8 275- strcasecmp of ';acc' and 'acc' is => int(-%d) 276- strcasecmp of ';acc' and 'Acc' is => int(-%d) 277- strcasecmp of ';acc' and 'aC' is => int(-%d) 278- strcasecmp of ';acc' and 'acCc' is => int(-%d) 279- strcasecmp of ';acc' and 'acd' is => int(-%d) 280- strcasecmp of ';acc' and '?acc' is => int(-%d) 281- strcasecmp of ';acc' and 'Acc!' is => int(-%d) 282- strcasecmp of ';acc' and '$!acc' is => int(%d) 283- strcasecmp of ';acc' and ';acc' is => int(0) 284 285*** comparing the strings in an 286Array 287( 288 [0] => 1 289 [1] => 0 290 [2] => 0 291 [3] => -1 292 [4] => -1 293 [5] => 294 [6] => 295 [7] => 296 [8] => 1 297 [9] => 1 298 [10] => 299 [11] => string 300) 301 302Iteration 0 303- strcasecmp of '1' and '1' is => int(0) 304- strcasecmp of '1' and '0' is => int(%d) 305- strcasecmp of '1' and '0' is => int(%d) 306- strcasecmp of '1' and '-1' is => int(%d) 307- strcasecmp of '1' and '-1' is => int(%d) 308- strcasecmp of '1' and '' is => int(%d) 309- strcasecmp of '1' and '' is => int(%d) 310- strcasecmp of '1' and '' is => int(%d) 311- strcasecmp of '1' and '1' is => int(0) 312- strcasecmp of '1' and '1' is => int(0) 313- strcasecmp of '1' and '' is => int(%d) 314- strcasecmp of '1' and 'string' is => int(-%d) 315 316Iteration 1 317- strcasecmp of '0' and '1' is => int(-%d) 318- strcasecmp of '0' and '0' is => int(0) 319- strcasecmp of '0' and '0' is => int(0) 320- strcasecmp of '0' and '-1' is => int(%d) 321- strcasecmp of '0' and '-1' is => int(%d) 322- strcasecmp of '0' and '' is => int(%d) 323- strcasecmp of '0' and '' is => int(%d) 324- strcasecmp of '0' and '' is => int(%d) 325- strcasecmp of '0' and '1' is => int(-%d) 326- strcasecmp of '0' and '1' is => int(-%d) 327- strcasecmp of '0' and '' is => int(%d) 328- strcasecmp of '0' and 'string' is => int(-%d) 329 330Iteration 2 331- strcasecmp of '0' and '1' is => int(-%d) 332- strcasecmp of '0' and '0' is => int(0) 333- strcasecmp of '0' and '0' is => int(0) 334- strcasecmp of '0' and '-1' is => int(%d) 335- strcasecmp of '0' and '-1' is => int(%d) 336- strcasecmp of '0' and '' is => int(%d) 337- strcasecmp of '0' and '' is => int(%d) 338- strcasecmp of '0' and '' is => int(%d) 339- strcasecmp of '0' and '1' is => int(-%d) 340- strcasecmp of '0' and '1' is => int(-%d) 341- strcasecmp of '0' and '' is => int(%d) 342- strcasecmp of '0' and 'string' is => int(-%d) 343 344Iteration 3 345- strcasecmp of '-1' and '1' is => int(-%d) 346- strcasecmp of '-1' and '0' is => int(-%d) 347- strcasecmp of '-1' and '0' is => int(-%d) 348- strcasecmp of '-1' and '-1' is => int(0) 349- strcasecmp of '-1' and '-1' is => int(0) 350- strcasecmp of '-1' and '' is => int(%d) 351- strcasecmp of '-1' and '' is => int(%d) 352- strcasecmp of '-1' and '' is => int(%d) 353- strcasecmp of '-1' and '1' is => int(-%d) 354- strcasecmp of '-1' and '1' is => int(-%d) 355- strcasecmp of '-1' and '' is => int(%d) 356- strcasecmp of '-1' and 'string' is => int(-%d) 357 358Iteration 4 359- strcasecmp of '-1' and '1' is => int(-%d) 360- strcasecmp of '-1' and '0' is => int(-%d) 361- strcasecmp of '-1' and '0' is => int(-%d) 362- strcasecmp of '-1' and '-1' is => int(0) 363- strcasecmp of '-1' and '-1' is => int(0) 364- strcasecmp of '-1' and '' is => int(%d) 365- strcasecmp of '-1' and '' is => int(%d) 366- strcasecmp of '-1' and '' is => int(%d) 367- strcasecmp of '-1' and '1' is => int(-%d) 368- strcasecmp of '-1' and '1' is => int(-%d) 369- strcasecmp of '-1' and '' is => int(%d) 370- strcasecmp of '-1' and 'string' is => int(-%d) 371 372Iteration 5 373- strcasecmp of '' and '1' is => int(-%d) 374- strcasecmp of '' and '0' is => int(-%d) 375- strcasecmp of '' and '0' is => int(-%d) 376- strcasecmp of '' and '-1' is => int(-%d) 377- strcasecmp of '' and '-1' is => int(-%d) 378- strcasecmp of '' and '' is => int(0) 379- strcasecmp of '' and '' is => int(0) 380- strcasecmp of '' and '' is => int(0) 381- strcasecmp of '' and '1' is => int(-%d) 382- strcasecmp of '' and '1' is => int(-%d) 383- strcasecmp of '' and '' is => int(0) 384- strcasecmp of '' and 'string' is => int(-%d) 385 386Iteration 6 387- strcasecmp of '' and '1' is => int(-%d) 388- strcasecmp of '' and '0' is => int(-%d) 389- strcasecmp of '' and '0' is => int(-%d) 390- strcasecmp of '' and '-1' is => int(-%d) 391- strcasecmp of '' and '-1' is => int(-%d) 392- strcasecmp of '' and '' is => int(0) 393- strcasecmp of '' and '' is => int(0) 394- strcasecmp of '' and '' is => int(0) 395- strcasecmp of '' and '1' is => int(-%d) 396- strcasecmp of '' and '1' is => int(-%d) 397- strcasecmp of '' and '' is => int(0) 398- strcasecmp of '' and 'string' is => int(-%d) 399 400Iteration 7 401- strcasecmp of '' and '1' is => int(-%d) 402- strcasecmp of '' and '0' is => int(-%d) 403- strcasecmp of '' and '0' is => int(-%d) 404- strcasecmp of '' and '-1' is => int(-%d) 405- strcasecmp of '' and '-1' is => int(-%d) 406- strcasecmp of '' and '' is => int(0) 407- strcasecmp of '' and '' is => int(0) 408- strcasecmp of '' and '' is => int(0) 409- strcasecmp of '' and '1' is => int(-%d) 410- strcasecmp of '' and '1' is => int(-%d) 411- strcasecmp of '' and '' is => int(0) 412- strcasecmp of '' and 'string' is => int(-%d) 413 414Iteration 8 415- strcasecmp of '1' and '1' is => int(0) 416- strcasecmp of '1' and '0' is => int(%d) 417- strcasecmp of '1' and '0' is => int(%d) 418- strcasecmp of '1' and '-1' is => int(%d) 419- strcasecmp of '1' and '-1' is => int(%d) 420- strcasecmp of '1' and '' is => int(%d) 421- strcasecmp of '1' and '' is => int(%d) 422- strcasecmp of '1' and '' is => int(%d) 423- strcasecmp of '1' and '1' is => int(0) 424- strcasecmp of '1' and '1' is => int(0) 425- strcasecmp of '1' and '' is => int(%d) 426- strcasecmp of '1' and 'string' is => int(-%d) 427 428Iteration 9 429- strcasecmp of '1' and '1' is => int(0) 430- strcasecmp of '1' and '0' is => int(%d) 431- strcasecmp of '1' and '0' is => int(%d) 432- strcasecmp of '1' and '-1' is => int(%d) 433- strcasecmp of '1' and '-1' is => int(%d) 434- strcasecmp of '1' and '' is => int(%d) 435- strcasecmp of '1' and '' is => int(%d) 436- strcasecmp of '1' and '' is => int(%d) 437- strcasecmp of '1' and '1' is => int(0) 438- strcasecmp of '1' and '1' is => int(0) 439- strcasecmp of '1' and '' is => int(%d) 440- strcasecmp of '1' and 'string' is => int(-%d) 441 442Iteration 10 443- strcasecmp of '' and '1' is => int(-%d) 444- strcasecmp of '' and '0' is => int(-%d) 445- strcasecmp of '' and '0' is => int(-%d) 446- strcasecmp of '' and '-1' is => int(-%d) 447- strcasecmp of '' and '-1' is => int(-%d) 448- strcasecmp of '' and '' is => int(0) 449- strcasecmp of '' and '' is => int(0) 450- strcasecmp of '' and '' is => int(0) 451- strcasecmp of '' and '1' is => int(-%d) 452- strcasecmp of '' and '1' is => int(-%d) 453- strcasecmp of '' and '' is => int(0) 454- strcasecmp of '' and 'string' is => int(-%d) 455 456Iteration 11 457- strcasecmp of 'string' and '1' is => int(%d) 458- strcasecmp of 'string' and '0' is => int(%d) 459- strcasecmp of 'string' and '0' is => int(%d) 460- strcasecmp of 'string' and '-1' is => int(%d) 461- strcasecmp of 'string' and '-1' is => int(%d) 462- strcasecmp of 'string' and '' is => int(%d) 463- strcasecmp of 'string' and '' is => int(%d) 464- strcasecmp of 'string' and '' is => int(%d) 465- strcasecmp of 'string' and '1' is => int(%d) 466- strcasecmp of 'string' and '1' is => int(%d) 467- strcasecmp of 'string' and '' is => int(%d) 468- strcasecmp of 'string' and 'string' is => int(0) 469 470*** comparing the strings in an 471Array 472( 473 [0] => 10.5 474 [1] => 1.5 475 [2] => 9.5 476 [3] => 11.5 477 [4] => 100.5 478 [5] => 105 479 [6] => -10.5 480 [7] => 10 481 [8] => 0.5 482) 483 484Iteration 0 485- strcasecmp of '10.5' and '10.5' is => int(0) 486- strcasecmp of '10.5' and '1.5' is => int(%d) 487- strcasecmp of '10.5' and '9.5' is => int(-%d) 488- strcasecmp of '10.5' and '11.5' is => int(-%d) 489- strcasecmp of '10.5' and '100.5' is => int(-%d) 490- strcasecmp of '10.5' and '105' is => int(-%d) 491- strcasecmp of '10.5' and '-10.5' is => int(%d) 492- strcasecmp of '10.5' and '10' is => int(%d) 493- strcasecmp of '10.5' and '0.5' is => int(%d) 494 495Iteration 1 496- strcasecmp of '1.5' and '10.5' is => int(-%d) 497- strcasecmp of '1.5' and '1.5' is => int(0) 498- strcasecmp of '1.5' and '9.5' is => int(-%d) 499- strcasecmp of '1.5' and '11.5' is => int(-%d) 500- strcasecmp of '1.5' and '100.5' is => int(-%d) 501- strcasecmp of '1.5' and '105' is => int(-%d) 502- strcasecmp of '1.5' and '-10.5' is => int(%d) 503- strcasecmp of '1.5' and '10' is => int(-%d) 504- strcasecmp of '1.5' and '0.5' is => int(%d) 505 506Iteration 2 507- strcasecmp of '9.5' and '10.5' is => int(%d) 508- strcasecmp of '9.5' and '1.5' is => int(%d) 509- strcasecmp of '9.5' and '9.5' is => int(0) 510- strcasecmp of '9.5' and '11.5' is => int(%d) 511- strcasecmp of '9.5' and '100.5' is => int(%d) 512- strcasecmp of '9.5' and '105' is => int(%d) 513- strcasecmp of '9.5' and '-10.5' is => int(%d) 514- strcasecmp of '9.5' and '10' is => int(%d) 515- strcasecmp of '9.5' and '0.5' is => int(%d) 516 517Iteration 3 518- strcasecmp of '11.5' and '10.5' is => int(%d) 519- strcasecmp of '11.5' and '1.5' is => int(%d) 520- strcasecmp of '11.5' and '9.5' is => int(-%d) 521- strcasecmp of '11.5' and '11.5' is => int(0) 522- strcasecmp of '11.5' and '100.5' is => int(%d) 523- strcasecmp of '11.5' and '105' is => int(%d) 524- strcasecmp of '11.5' and '-10.5' is => int(%d) 525- strcasecmp of '11.5' and '10' is => int(%d) 526- strcasecmp of '11.5' and '0.5' is => int(%d) 527 528Iteration 4 529- strcasecmp of '100.5' and '10.5' is => int(%d) 530- strcasecmp of '100.5' and '1.5' is => int(%d) 531- strcasecmp of '100.5' and '9.5' is => int(-%d) 532- strcasecmp of '100.5' and '11.5' is => int(-%d) 533- strcasecmp of '100.5' and '100.5' is => int(0) 534- strcasecmp of '100.5' and '105' is => int(-%d) 535- strcasecmp of '100.5' and '-10.5' is => int(%d) 536- strcasecmp of '100.5' and '10' is => int(%d) 537- strcasecmp of '100.5' and '0.5' is => int(%d) 538 539Iteration 5 540- strcasecmp of '105' and '10.5' is => int(%d) 541- strcasecmp of '105' and '1.5' is => int(%d) 542- strcasecmp of '105' and '9.5' is => int(-%d) 543- strcasecmp of '105' and '11.5' is => int(-%d) 544- strcasecmp of '105' and '100.5' is => int(%d) 545- strcasecmp of '105' and '105' is => int(0) 546- strcasecmp of '105' and '-10.5' is => int(%d) 547- strcasecmp of '105' and '10' is => int(%d) 548- strcasecmp of '105' and '0.5' is => int(%d) 549 550Iteration 6 551- strcasecmp of '-10.5' and '10.5' is => int(-%d) 552- strcasecmp of '-10.5' and '1.5' is => int(-%d) 553- strcasecmp of '-10.5' and '9.5' is => int(-%d) 554- strcasecmp of '-10.5' and '11.5' is => int(-%d) 555- strcasecmp of '-10.5' and '100.5' is => int(-%d) 556- strcasecmp of '-10.5' and '105' is => int(-%d) 557- strcasecmp of '-10.5' and '-10.5' is => int(0) 558- strcasecmp of '-10.5' and '10' is => int(-%d) 559- strcasecmp of '-10.5' and '0.5' is => int(-%d) 560 561Iteration 7 562- strcasecmp of '10' and '10.5' is => int(-%d) 563- strcasecmp of '10' and '1.5' is => int(%d) 564- strcasecmp of '10' and '9.5' is => int(-%d) 565- strcasecmp of '10' and '11.5' is => int(-%d) 566- strcasecmp of '10' and '100.5' is => int(-%d) 567- strcasecmp of '10' and '105' is => int(-%d) 568- strcasecmp of '10' and '-10.5' is => int(%d) 569- strcasecmp of '10' and '10' is => int(0) 570- strcasecmp of '10' and '0.5' is => int(%d) 571 572Iteration 8 573- strcasecmp of '0.5' and '10.5' is => int(-%d) 574- strcasecmp of '0.5' and '1.5' is => int(-%d) 575- strcasecmp of '0.5' and '9.5' is => int(-%d) 576- strcasecmp of '0.5' and '11.5' is => int(-%d) 577- strcasecmp of '0.5' and '100.5' is => int(-%d) 578- strcasecmp of '0.5' and '105' is => int(-%d) 579- strcasecmp of '0.5' and '-10.5' is => int(%d) 580- strcasecmp of '0.5' and '10' is => int(-%d) 581- strcasecmp of '0.5' and '0.5' is => int(0) 582 583#### Testing Miscelleneous inputs #### 584--- Testing objects --- 585int(-%d) 586 587--- Testing arrays --- 588 589Warning: strcasecmp() expects parameter 2 to be string, array given in %s on line %d 590NULL 591int(%d) 592int(%d) 593 594--- Testing a longer and heredoc string --- 595int(0) 596int(-%d) 597int(%d) 598 599--- Testing a heredoc null string --- 600int(-%d) 601int(0) 602int(-%d) 603 604--- Testing simple and complex syntax strings --- 605int(-%d) 606int(-%d) 607 608Notice: Undefined variable: strS in %s on line %d 609int(%d) 610int(-%d) 611int(-%d) 612 613--- Testing binary safe and binary chars --- 614int(%d) 615int(-%d) 616int(0) 617int(0) 618int(%d) 619int(%d) 620int(%d) 621 622--- Comparing long float values --- 623int(0) 624int(-%d) 625int(0) 626 627#### checking error conditions #### 628Warning: strcasecmp() expects exactly 2 parameters, 0 given in %s on line %d 629 630Warning: strcasecmp() expects exactly 2 parameters, 1 given in %s on line %d 631 632Warning: strcasecmp() expects exactly 2 parameters, 1 given in %s on line %d 633 634Warning: strcasecmp() expects exactly 2 parameters, 3 given in %s on line %d 635Done 636