Hello friends, (PHP reverse number program) we are selecting PHP language because in PHP easy language compile to author web languages

Today i show you reverse number of program in php.so for that start your notepad++ or visual studio code and

And I show you the full program step by step. first, we will be declaring variables. first, We will open the PHP tag. After then we taking the two variables. And in the first variable, we will Give any value. After that, we will put a while loop.

And here we take zero as the reverse name variable. after that, we need one more variable and the variable name is rev,

the first here we will need to check 2 3 4 5 6 in greater than one or not. after that number is modulus by time.

After that, we will multiply 10 to the reverse number and after that, we add it to the given variable.

that we are using here division operation and we are doing a division is given number divided by 10.

And then after that we will print that number.

If you want to learn fresh new courses then visit our website:-https://learningpoints.in/

PHP reverse number program


$num = 23456;  
$revnum = 0;  
while ($num > 1)  
$rem = $num % 10;  
$revnum = ($revnum * 10) + $rem;  
$num = ($num / 10);   
echo "Reverse number of 23456 is:.$revnum";  

this is a output of PHP reverse number program

Here I am giving the number in 23456 and after that it will be converted into reverse format 65432

Basically, With our PHP session, We gonna create a dynamic website.

that will help you to make yourself, To a great web developer!

And also want to learn patterns in Java and Armstrong numbers in Java in different different types of programs in Java.

so visit our website and click here:-https://learningpoints.in/category/java/

thank you for coming to our website please share with your friends And do comment

Thank you.

Leave a Reply

Your email address will not be published.