R4R Team working to provide free of cost for experienced and freshers

Tutorials | Examples|Interview Questions and Answers|Java Tutorials| C Tutorials | C++ Tutorials | Spring Tutorials| Hibernate Tutorials | JSP Tutorials | Servelets Tutorials| C# Tutorials | PHP Tutorials etc , Basics | Download Software | Data Types | Variables | Constant | Storage & Classes | Operators | Decisions Making | Loops | Functions| Numbers | Arrays | Pointers | String | Datastructure | Expressions | Preprocessor Statement | I/O | Exception Handling | OOPs Tutorial | Classes and object |C++ Inheritance Overloading | Polymorphism | Abstraction | Encapsulation | Interfaces | Multithreading etc

PHP Programing language

Print a odd Number 1 to 100 using while loop
Previous Home Next

<html>
<head>
<title>print odd number</title>
</head>
<body>
<?php
$num = 1;
while ( $num <= 100 ){ 
  print "$num</br>";
  $num += 2;
}
?>
</body>
</html>
output

135791113151719212325272931333537394143454749515

35557596163656769717375777981838587899193959799

Previous Home Next