php 基本数据类型

Posted on 2010-03-01 12:33  FreeSkyCD  阅读(293)  评论(0编辑  收藏  举报

阅读: 22 评论: 0 作者: looping 发表于 2010-03-01 12:33 原文链接

PHP has a total of eight types: integers, doubles, Booleans, strings, arrays, objects, NULL, and

resources.

✦Integers are whole numbers, without a decimal point, like 495. ✦ Doubles are floating-point numbers, like 3.14159 or 49.0. ✦ Booleans have only two possible values: TRUE and FALSE. ✦ NULL is a special type that only has one value: NULL. ✦ Strings are sequences of characters, like ‘PHP 4.0 supports string operations.’ ✦ Arrays are named and indexed collections of other values. ✦ Objects are instances of programmer-defined classes, which can package up both other kinds of values and functions that are specific to the class. ✦ Resources are special variables that hold references to resources external to PHP (such as database connections).

 

Of these, the first five are simple types, and the next two (arrays and objects) are compound—
the compound types can package up other arbitrary values of arbitrary type, whereas the
simple types cannot.

评论: 0 查看评论 发表评论

找优秀程序员,就在博客园


最新新闻:
· IBM发布第五代X架构 打破X86系统30年技术局限(2010-03-03 22:47)
· 互联网手机业务成香馍馍 上海电信盯牢3G市场(2010-03-03 22:38)
· Twitter信息总量即将突破100亿条大关(2010-03-03 22:34)
· Opera为何无法进一步拓展市场(2010-03-03 21:38)
· Symbian版 Skype登陆诺基亚Ovi Store(2010-03-03 21:04)

编辑推荐:Opera为何无法进一步拓展市场

网站导航:博客园首页  个人主页  新闻  闪存  小组  博问  社区  知识库

Copyright © 2024 FreeSkyCD
Powered by .NET 9.0 on Kubernetes