[ create a new paste ] login | about

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

PHP, pasted on Jun 19:
1
2
3
4
5
6
7
8
9
10
11
<?php

$string = "sometext::sometext.0 = INTEGER: 254";
sscanf ($string, "sometext::sometext.0 = INTEGER: %d" , $number );
echo $number;

echo PHP_EOL;

$string = "sometext::sometext.0 = INTEGER: 123456789";
sscanf ($string, "sometext::sometext.0 = INTEGER: %d" , $number );
echo $number;


Output:
1
2
254
123456789


Create a new paste based on this one


Comments: