473,395 Members | 1,968 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

how i can display numbers ?

49
i want to display number using echo, i wrote the following code
Expand|Select|Wrap|Line Numbers
  1. <?php
  2. $a= 01020;
  3. echo $a;
  4. ?>
Expand|Select|Wrap|Line Numbers
  1. the result :582 
i don't understand the result.
this happen only if i add zero to the first place in the number i mean if i write 1020 there is no problem the number will be appeared as it.
please i need an explanation for that.
thanks in advance
shreen
Aug 2 '10 #1

✓ answered by improvcornartist

Preceding the number with a zero makes it no longer an integer, but octal notation. This page has a little additional info.

2 1534
improvcornartist
303 Expert 100+
Preceding the number with a zero makes it no longer an integer, but octal notation. This page has a little additional info.
Aug 2 '10 #2
orked
49
thank you very much i understand the point now.
Aug 3 '10 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

0
by: AshifToday | last post by:
this was my and my frineds little project in earlier classes, the program seperates the composite and prime numbers in two sections of the screen ===================== /* This program has...
4
by: google | last post by:
<html> <head> <title>JavaScript Replace</title> <script language="JavaScript1.1" type="text/javascript"> function phils_image_price(input) { //declare variables var output="" var position=0
1
by: arun.hallan | last post by:
My datagrid displays large numbers pulled from the database in standard form. EG - 1,172,060 is displayed as -1.17206e+006 How do i get it to display numbers in full?
4
by: Samantha | last post by:
I am new to Python and am attempting to write a routine that will display a five game selection for a power ball drawing. I think I have the random drawing set to work ok, but I want to have the...
1
by: yumyu | last post by:
Hi, I am trying to display numbers with a thousand seperator. If i enter in 20000 then the output would be 20,000. How do I get that comma? Thanks
17
by: Ron | last post by:
I want to write a program that will accept a number in a textbox for example 23578 and then in a label will display the sum of the odd and even number like this... the textbox containsthe number...
19
by: aa | last post by:
when I ourput data from Access, numbers bigger than 999 are shown with letter "B" inserted into the 4th position left to the coma. (in my w2k regional settings I have the decimal dot separator set...
1
by: dheema | last post by:
hi, i would like to knw how to format the display of numbers from ms access database in asp page, in the database its dispalying properly but not in the asp page. i try format currency..its not...
6
by: AhmedGY | last post by:
Hi, I'm new to C#, and doing a simple calculator application, it's completed now and calculates well, i wanna provide the interface with hotkeys so when the user press a number lets say "1" on the...
6
by: twiggymoo | last post by:
I want to have a popup message box for certain cases. In the field I want an event onclick that does this: If = then msgbox "Class is Full" Elseif > then msgbox "You have exceeded the class...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.