Results of 1 - 10 of about 30 for digit (0.003 sec.)
- bcround — 任意精度数値を丸める | PHP 8.3 12379
- bcround (PHP 8 >= 8.4.0) bcround — 任意精度数値を丸める 説明 function bcround ( string $num , int $precision = 0 , RoundingMode $mode = RoundingMode::HalfAwayFromZero ): string num を、指定した precision (小数点以下の桁数)に丸めた値を返しま
... bcround() で precision を指定し、 異なる mode を指定した例 <?php echo 'Using RoundingMode::HalfAwayFromZero with 1 decimal digit precision' . PHP_EOL ; var_dump ( bcround ( 1.55 , 1 , RoundingMode :: HalfAwayFromZero )); var_dump ( bcround (- 1.55 , 1 ... , RoundingMode :: HalfAwayFromZero )); echo PHP_EOL ; echo 'Using RoundingMode::HalfTowardsZero with 1 decimal digit precision' . PHP_EOL ; var_dump ( bcround ( 1.55 , 1 , RoundingMode :: HalfTowardsZero )); var_dump ( bcround (- 1.55 , 1 ... , RoundingMode :: HalfTowardsZero )); echo PHP_EOL ; echo 'Using RoundingMode::HalfEven with 1 decimal digit precision' . PHP_EOL ; var_dump ( bcround ( 1.55 , 1 , RoundingMode :: HalfEven )); var_dump ( bcround (- 1.55 , 1 , Round ...
-
https://man.mtool.work/php/8.3/function.bcround.html
- BcMath\Number::round — 任意精度数値を丸める | PHP 8.3 11356
- BcMath\Number::round (PHP 8 >= 8.4.0) BcMath\Number::round — 任意精度数値を丸める 説明 public function BcMath\Number::round ( int $precision = 0 , RoundingMode $mode = RoundingMode::HalfAwayFromZero ): BcMath\Number $this を、指定した preci
... th\Number ( '1.55' ); $negative = new BcMath\Number ( '-1.55' ); echo 'Using RoundingMode::HalfAwayFromZero with 1 decimal digit precision' . PHP_EOL ; var_dump ( $positive -> round ( 1 , RoundingMode :: HalfAwayFromZero ), $negative -> round ( 1 , Ro ... undingMode :: HalfAwayFromZero ), ); echo PHP_EOL ; echo 'Using RoundingMode::HalfTowardsZero with 1 decimal digit precision' . PHP_EOL ; var_dump ( $positive -> round ( 1 , RoundingMode :: HalfTowardsZero ), $negative -> round ( 1 , Rou ... ndingMode :: HalfTowardsZero ), ); echo PHP_EOL ; echo 'Using RoundingMode::HalfEven with 1 decimal digit precision' . PHP_EOL ; var_dump ( $positive -> round ( 1 , RoundingMode :: HalfEven ), $negative -> round ( 1 , RoundingMo ...
-
https://man.mtool.work/php/8.3/bcmath-number.round.html
- strftime — ロケールの設定に基づいてローカルな日付・時間をフォーマットする | PHP... 11356
- strftime (PHP 4, PHP 5, PHP 7, PHP 8) strftime — ロケールの設定に基づいてローカルな日付・時間をフォーマットする 警告 この関数は PHP 8.1.0 で 非推奨 になります。この関数に頼らないことを強く推奨します。 この関数の代替として、これらが使えます:
... s = array( 'A' => 'A full textual representation of the day' , 'B' => 'Full month name, based on the locale' , 'C' => 'Two digit representation of the century (year divided by 100, truncated to an integer)' , 'D' => 'Same as "%m/%d/%y"' , 'E' => '' , ... 'F' => 'Same as "%Y-%m-%d"' , 'G' => 'The full four-digit version of %g' , 'H' => 'Two digit representation of the hour in 24-hour format' , 'I' => 'Two digit representation of the ... hour in 12-hour format' , 'J' => '' , 'K' => '' , 'L' => '' , 'M' => 'Two digit representation of the minute' , 'N' => '' , 'O' => '' , 'P' => 'lower-case "am" or "pm" based on the given time' , 'Q' => ...
-
https://man.mtool.work/php/8.3/function.strftime.html
- ctype_digit — 数字かどうかを調べる | PHP 8.3 11014
- ctype_digit (PHP 4 >= 4.0.4, PHP 5, PHP 7, PHP 8) ctype_digit — 数字かどうかを調べる 説明 function ctype_digit ( mixed $text ): bool 与えられた文字列 text のすべての文字が 数字であるかどうかを調べます。 パラメータ text 調べる文字列。 注意 :
... 場合に true 、そうでない場合に false を返します。 空文字列を渡して呼び出した場合、結果は常に false になります。 例 例1 ctype_digit() の例 <?php $strings = array( '1820.20' , '10002' , 'wsl!12' ); foreach ( $strings as $testcase ) { if ( ctype_digit ( $t ... estcase )) { echo "The string $testcase consists of all digits.\n" ; } else { echo "The string $testcase does not consist of all digits.\n" ; } } ?> 上の例の出力は以下となります。 The ... string 1820.20 does not consist of all digits. The string 10002 consists of all digits. The string wsl!12 does not consist of all digits. 例2 ctype_digit() で文字列と整 ...
-
https://man.mtool.work/php/8.3/function.ctype-digit.html
- IntlChar::digit — コードポイントの10進の数値を、指定された基数で返す | PHP 8.3 10738
- IntlChar::digit (PHP 7, PHP 8) IntlChar::digit — コードポイントの10進の数値を、指定された基数で返す 説明 public static function IntlChar::digit ( int | string $codepoint , int $base = 10 ): int | false | null 指定されたコードポイントの10進の
... はまる場合、 有効な値であると見なされます。 指定された文字が、10進数の値である場合。 これは、general category "Nd" (decimal digit numbers)、かつ Numeric_Type of "Decimal" である場合です。 この場合、値はその文字の10進の数値になります。 指定された文字が、 ... の関数の返り値を調べるには ===演算子 を 使用してください。 例 例1 さまざまなコードポイントの例 <?php var_dump ( IntlChar :: digit ( "0" )); var_dump ( IntlChar :: digit ( "3" )); var_dump ( IntlChar :: digit ( "A" , 16 )); var_dump ( IntlChar :: digit ... ( "A" )); ?> 上の例の出力は以下となります。 int(0) int(3) int(10) bool(false) 参考 IntlChar::forDigit() - 指定された整数と基数を表す文字を取得する IntlChar::charDigitValue() - 10進数の桁の文字を桁の値として取得する IntlChar: ...
-
https://man.mtool.work/php/8.3/intlchar.digit.html
- round — 浮動小数点数を丸める | PHP 8.3 9309
- round (PHP 4, PHP 5, PHP 7, PHP 8) round — 浮動小数点数を丸める 説明 function round ( int | float $num , int $precision = 0 , int | RoundingMode $mode = RoundingMode::HalfAwayFromZero ): float num を、指定した precision (小数点以下の桁数)に
... th 8.5 float(9) float(8) float(8) float(9) 例4 桁数を指定した mode の例 <?php echo 'Using PHP_ROUND_HALF_UP with 1 decimal digit precision' . PHP_EOL ; var_dump ( round ( 1.55 , 1 , PHP_ROUND_HALF_UP )); var_dump ( round (- 1.55 , 1 , PHP_ROUND_HALF_U ... P )); echo PHP_EOL ; echo 'Using PHP_ROUND_HALF_DOWN with 1 decimal digit precision' . PHP_EOL ; var_dump ( round ( 1.55 , 1 , PHP_ROUND_HALF_DOWN )); var_dump ( round (- 1.55 , 1 , PHP_ROUND_HALF ... _DOWN )); echo PHP_EOL ; echo 'Using PHP_ROUND_HALF_EVEN with 1 decimal digit precision' . PHP_EOL ; var_dump ( round ( 1.55 , 1 , PHP_ROUND_HALF_EVEN )); var_dump ( round (- 1.55 , 1 , PHP_ROUND_HALF ...
-
https://man.mtool.work/php/8.3/function.round.html
- IntlChar::forDigit — 指定された整数と基数を表す文字を取得する | PHP 8.3 9097
- IntlChar::forDigit (PHP 7, PHP 8) IntlChar::forDigit — 指定された整数と基数を表す文字を取得する 説明 public static function IntlChar::forDigit ( int $digit , int $base = 10 ): int 指定された整数値と基数を表現する文字を判定します。 基数の値が
... た基数に対して整数値が無効な場合、 null 文字 ( U+0000 ) を返します。 基数は 2 以上 36 以下の場合に有効です。 整数値は、 0 <= digit < radix の場合に有効です。 整数値が 10 より小さい場合、 '0' (ASCII の文字「0」) + 指定された整数値の値を返します。 そうでな ... い場合、'a' + 指定された整数値 - 10 の値を返します。 パラメータ digit 文字に変換する整数値。 base 基数 (デフォルトは 10 ) 戻り値 指定された整数値と基数を表す、 文字を数値として返します。 例 例 ... 1 さまざまなコードポイントの例 <?php var_dump ( IntlChar :: forDigit ( 0 )); var_dump ( IntlChar :: forDigit ( 3 )); var_dump ( IntlChar :: forDigit ( 3 , 10 )); var_dump ( IntlChar :: forDig ...
-
https://man.mtool.work/php/8.3/intlchar.fordigit.html
- Parle pattern matching | PHP 8.3 8837
- Parle pattern matching Parle supports regex matching similar to flex. Also supported are the following POSIX character sets: [:alnum:] , [:alpha:] , [:blank:] , [:cntrl:] , [:digit:] , [:graph:] , [:lower:] , [:print:] , [:punct:] , [:space
... :] , [:upper:] , [:xdigit:] . The Unicode character classes are currently not enabled by default, pass --enable-parle-utf32 to make them available. ... r Carriage return. \f Form feed, \x0c. \t Horizontal tab, \x09. \v Vertical tab, \x0b. \oct Character specified by a three-digit octal code. \xhex Character specified by a hex code. \cchar Named control character. Character classes Character classes S ... p-tv-z] . [^...] A single character not listed and not contained within a listed range. . Any character, default [^\n]. \d Digit character, [0-9] . \D Non-digit character, [^0-9] . \s White space character, [ \t\n\r\f\v] . \S Non-white space character ...
-
https://man.mtool.work/php/8.3/parle.pattern.matching.html
- ジェネレータとは | PHP 8.3 8415
- ジェネレータとは (PHP 5 >= 5.5.0, PHP 7, PHP 8) ジェネレータを使えば、シンプルな イテレータ を簡単に実装できます。 Iterator インターフェイスを実装したクラスを用意する オーバーヘッドや複雑さを心配する必要はありません。 ジェネレータを使うと、
... ; $i += $step ) { yield $i ; } } } /* * 次の例で、range() と xrange() が同じ結果を返すことに注目しましょう */ echo 'Single digit odd numbers from range(): ' ; foreach ( range ( 1 , 9 , 2 ) as $number ) { echo " $number " ; } echo "\n" ; echo 'Single d ... rom xrange(): ' ; foreach ( xrange ( 1 , 9 , 2 ) as $number ) { echo " $number " ; } 上の例の出力は以下となります。 Single digit odd numbers from range(): 1 3 5 7 9 Single digit odd numbers from xrange(): 1 3 5 7 9 Generator オブジェクト ジェネレータ関 ...
-
https://man.mtool.work/php/8.3/language.generators.overview.html
- IntlChar クラス | PHP 8.3 7944
- IntlChar クラス (PHP 7, PHP 8) はじめに IntlChar クラスは、 Unicode 文字に関する情報にアクセスするための、 たくさんの便利メソッドを提供しています。 このクラスのメソッドと定数は、 依存している ICU ライブラリで使われている名前や振る舞いにとて
... ALUE ; public const int PROPERTY_ALPHABETIC ; public const int PROPERTY_BINARY_START ; public const int PROPERTY_ASCII_HEX_DIGIT ; public const int PROPERTY_BIDI_CONTROL ; public const int PROPERTY_BIDI_MIRRORED ; public const int PROPERTY_DASH ; publ ... BASE ; public const int PROPERTY_GRAPHEME_EXTEND ; public const int PROPERTY_GRAPHEME_LINK ; public const int PROPERTY_HEX_DIGIT ; public const int PROPERTY_HYPHEN ; public const int PROPERTY_ID_CONTINUE ; public const int PROPERTY_ID_START ; public c ... X_BLANK ; public const int PROPERTY_POSIX_GRAPH ; public const int PROPERTY_POSIX_PRINT ; public const int PROPERTY_POSIX_XDIGIT ; public const int PROPERTY_CASED ; public const int PROPERTY_CASE_IGNORABLE ; public const int PROPERTY_CHANGES_WHEN_LOWE ...
-
https://man.mtool.work/php/8.3/class.intlchar.html