Android programmers learn PHP development (8)-constant predefined constant operator No.-PhpStorm

Source: Internet
Author: User
Tags natural logarithm
Constants, pre-defined constants (learn more), and operators (when you see this blog, you don't need to know how to calculate these operators, but just understand the operators ), when the variable value is string a, ++ and -- take a look at it ~ Arithmetic operator number example. Constants, pre-defined constants (learn more), and operators (when you see this blog, you don't need to know how to calculate these operators, but just understand the operators ), when the variable value is string a, ++ and -- take a look at it ~

Arithmetic operator number example.

 ";}Else {echo" defined false "; echo"
";}/*** Pre-defined constant (understand) */echo 'predefined constant commonly used by PHP :'.'
'; Echo' The Current php version is (PHP_VERSION): '. PHP_VERSION .'
'; // The Current php version is (PHP_VERSION): 5.6.29 echo 'current operating system type (PHP_ OS):'. PHP_ OS .'
'; // The current operating system type (PHP_ OS): WINNT echo' the interface between the web server and PHP is (PHP_SAPI): '. PHP_SAPI .'
'; // The interface between the web server and PHP is (PHP_SAPI): cgi-fcgi echo 'the maximum integer number (PHP_INT_MAX):'. PHP_INT_MAX .'
'; // The maximum integer number (PHP_INT_MAX): 2147483647 echo 'php default include path (DEFAULT_INCLUDE_PATH):'. DEFAULT_INCLUDE_PATH .'
'; // Default include path of php (DEFAULT_INCLUDE_PATH):.; C: \ php \ pear echo 'installation path of pear (PEAR_INSTALL_DIR):'. PEAR_INSTALL_DIR .'
'; // Pear installation path (PEAR_INSTALL_DIR): C: \ php \ pear echo 'pear extension path (PEAR_EXTENSION_DIR):'. PEAR_EXTENSION_DIR .'
'; // Pear extension path (PEAR_EXTENSION_DIR): C: \ php \ ext echo 'php execution path (PHP_BINDIR):'. PHP_BINDIR .'
'; // Php execution path (PHP_BINDIR): C: \ php echo 'The php extension module path is (PHP_LIBDIR):'. PHP_LIBDIR .'
'; // Php extension module path: (PHP_LIBDIR): C: \ php echo' pointing to the nearest error (E_ERROR): '. E_ERROR .'
'; // Point to the nearest error (E_ERROR): 1 echo' points to the nearest warning (E_WARNING): '. E_WARNING .'
'; // Point to the nearest warning area (E_WARNING): 2 echo' points to the nearest note area (E_NOTICE): '. E_NOTICE .'
'; // Point to the nearest note (E_NOTICE): 8 echo 'natural logarithm e value (M_E):'. M_E .'
'; // Natural logarithm e value (M_E): 2.718281828459 echo' mathematical circumference rate value (M_PI): '. M_PI .'
'; // Mathematical value of the circumference rate (M_PI): 3.1415926535898 echo 'logical TRUE value (TRUE):'. TRUE .'
'; // Logical TRUE value (TRUE): 1 echo' logical FALSE value (FALSE): '. FALSE .'
'; // Logical dummy value (FALSE): echo 'number of current file lines (_ LINE _):'. _ LINE __.'
'; // Number of current FILE lines (_ LINE _): 43 echo 'current FILE path name (_ FILE _):'. _ FILE __.'
'; // Path name of the current FILE (_ FILE _): C: \ Users \ iwanghang \ PhpstormProjects \ untitled1 \ ceshi. php echo 'name of the currently called FUNCTION (_ FUNCTION __):'. _ FUNCTION __.'
'; // Name of the currently called FUNCTION (_ FUNCTION _): echo' CLASS name (_ CLASS _): '. _ CLASS __.'
'; // CLASS name (_ CLASS _): echo' METHOD name of the CLASS (_ METHOD _): '. _ METHOD __.'
'; // METHOD name of the class (_ METHOD _):/*** operator number (you do not need to know how these operators are computed when you see this blog, just take a look at the operators) * for example, 1 + 1. both 1 and 2 are computing clouds. + is an operator * unary operator: + 1,-1, ++ ,--,! * Binary operators: +,-, *,/, %,>, <, = * ternary operators: for example, 1? 2: 3 * arithmetic operator number: +,-, *,/, %, ++, -- * value assignment operator number: =, + =,-=, * =,/=, % = * comparison operator No.: >,<,=, >=, <=, == ,! = ,! = * Bit operator number: &, |, ^, ~,>, <* Other operators :?, :, @, =>,-> * // *** Arithmetic operator number: +,-, *,/, %, ++, -- */echo "arithmetic operator number:
"; $ A = 13; $ B = 2; echo $ a + $ B ."
"; // 15 echo $ a-$ B ."
"; // 11 echo $ a * $ B ."
"; // 26 echo $ a/$ B ."
"; // 6.5 echo $ a % $ B ."
"; // 1 echo $ a ++ ."
"; // 13 when the operation ends, a is 13, and the value of a is 14 echo $ --."
"; // 14 the end value of Operation a is 14, and the value of a is 13 echo ++ $ ."
"; // 14. the end value of Operation a is 14 echo -- $ ."
"; // 13 the end a value is 13 $ x =" a "; $ x ++; echo $ x ."
"; // B $ x ++; echo $ x ."
"; // C $ x --; echo $ x ."
"; // C $ x --; echo $ x ."
"; // C ++ $ x; echo $ x ."
"; // D -- $ x; echo $ x ."
"; // D

The above is the content for Android programmers to learn PHP development (8)-constant pre-defined constant operator number-PhpStorm. For more information, see PHP Chinese network (www.php1.cn )!

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.