Data types in PHP :
- String
- Integer
- Float
- Boolean
- Array
- Object
- Null
- Resource
String Data type:
String is a sequence of word as like as "What's up world".
For example :
<php?
$tst="This is my first project";
echo '$tst';
?>
Integer Data Type :
Integer is a number without decimals. It is a number between 125, +125,-125.
Integers Rules:
- A whole number must have no less than one digit (0-9)
- A whole number can't contain comma or spaces
- A whole number must not have a decimal point
- A number can be either positive or negative
- Numbers can be indicated in three configurations: decimal (10-based), hexadecimal (16-based - prefixed with 0x) or octal (8-based - prefixed with 0).
No comments:
Post a Comment