computers

computers

View Answers

May 1, 2008 at 6:45 PM

Hi friend,

import java.io.*;
import java.util.*;
import java.util.Stack;

public class StackExample {
public static void main(String[] args){
try{
BufferedReader object = new BufferedReader(new InputStreamReader(System.in));
System.out.println("Enter number");
int num= Integer.parseInt(object.readLine());
int n = num;
int rev=0;
System.out.println("Number: ");
System.out.println(" "+ num);
for (int i=0; i<=num; i++){
int r=num%10;
num=num/10;
rev=rev*10+r;
i=0;
}
System.out.println("After reversing the number: "+ " ");
System.out.println(" "+ rev);
if(n == rev){
System.out.print("Number is palindrome!");
}
else{
System.out.println("Number is not palindrome!");
}
}
catch(Exception e){
System.out.println("Out of range!");
}
System.out.println("Shortened pack");
Stack lifo = new Stack();
for (int i = 1; i <= 12; i++){
lifo.push(new Integer(i));
}
// Last in first out means reverse order
while(!lifo.empty()){
System.out.print(lifo.pop());
System.out.print(',');
}
// Empty, let's lift off!
System.out.println("LIFT-OFF!");
}
}

--------------------------------

read for more information,

http://www.roseindia.net/java/









Related Tutorials/Questions & Answers:
computers - Java Beginners
computers   Describe any 5 methods in any of the library classes of java?  Hi Friend, Please visit the following link: http://www.roseindia.net/java/java-get-example/index.shtml Here you will get lot
computers - Java Beginners
Advertisements
computers - Java Beginners
computers - Java Beginners
computers - Java Beginners
computers - Java Beginners
Computers - Java Beginners
Computers - Java Beginners
Computers - Java Beginners
computers - Java Server Faces Questions
How to develope web service with exachanging xml message between computers using SOAP
How to develope web service with exachanging xml message between computers using SOAP  Hi Friends, I want to developed a webservice using soap as a protocol,in this webservice the client sends a set of 15 parameters and program
E Book Witing
Ebook writing eBook Writing As computers are gaining control of the world, the trend of paper books is out and that of eBooks are sweeping
Java UDP
Java UDP       TCP and UDP are transport protocols used for communication between computers. UDP(User Datagram Protocol) is a very simple connectionless protocol. UDP can
EBook Witing
eBook Writing As computers are gaining control of the world, the trend of paper books is out and that of eBooks are sweeping in. Writing and publishing eBooks has become hugely popular amongst writers
Computers Website Development
Domain Name
The domain name system (DNS) is a series of letters and numbers that are separated by periods and used to name organizations, computers and addresses on the Internet. The domain name is the way that Internet names are located
The Open Source World is a Big Part of PHP
The PHP scripting language is something that can work on many types of computers and can be used alongside HTML. It is also able to work with a variety of different forms of technology. The big reason for this comes from how PHP is an open
Amazon Web Services (AWS)
, magazines, DVDs, videos, electronics, computers, software, apparel &
What is ASCII?
characters in most of the computers that can be displayed on the computer screen... computers. IBM has its own built-in-code called EBCDIC code containing 256
What is Mobile Website
What is Mobile Website Mobile websites are specially designed for viewing mobile contents on Mobile Phones. Earlier websites were seen only on computers... very slower speed. So websites for computers cannot function well on mobile
ASCII values table
ASCII values table          ASCII stands for American Standard Code for Information Interchange. Computers can only understand numbers, so an ASCII
PHP Is Great for Website Creation
PHP is one of the most commonly used and understood types of website creation scripts in the world. It is being used by all sorts of different computers and is being loaded onto many servers. Here are some reasons why PHP is so great
Java for complete beginners
Java Guide is available at RoseIndia that help beginners to master the language. Because of its usefulness in both software development for computers and application development for mobile phone, Java is in great demand and so
Work Email- Dos and Don?ts
Work Email- Dos and Don’ts       Introduction With the proliferation of computers... of computers, it is very easy to type out everything you feel onto the screen
Remote Desktop Setting in Windows 8
In windows 8 operating system you can easily access other computers inside the network by enabling the Remote Desktop Connection in your PC. 1..._TO_REPLACE_4 5. Mark the 'Allow connections only from computers running Remote
EJB, Enterprise java bean, EJB Intoduction- Enterprise Java Beans (EJB) - An Introduction
of the system to be located on separate computers located in different locations... for servicing the clients in other computers. Object-oriented
Flex Mobile Phone Game Development
, iPhone, iPod, smart phones, mobile phones, computers, and on many gazettes
Top 10 Web Development Skills
of mobile devices that surpassed the traditional computers and devices as points
Windows 8 Operating System
Windows 8 is the latest innovation, which has been launched to make easy handling of the Windows operating system. Launched by the Microsoft it is expected to make easier for the use on personal computers and also for home and business
Intranet Application Development, Intranet Application Development Solutions, Intranet Design
Intranet Application Development Intranet Application Development Services India An intranet is a network of private computers linked together and using different web technologies to share the enterprise's
What is E-Commerce Web Design
conducting of business via Internet with the help of computers
What is procedure
What is procedure  What is procedure in computers? What are the primary categories of procedures
jade technology
jade technology  1)how message is passed using jade technology ? 2)how LAN (local area network) is established between two computers
jade technology
jade technology  1)how message is passed using jade technology ? 2)how LAN (local area network) is established between two computers
jade technology
jade technology  1)how message is passed using jade technology ? 2)how LAN (local area network) is established between two computers
How do i slow down the game (othello game)??
an othello game that can be played by 2 humans , human and computer and two computers. Everything works correctly but the problem is that when 2 computers play... the 2 computers is very fast, for that i tried to use the timer but it give me
Java Image Browsing Applet
Java Image Browsing Applet  Hi. I want to create an applet which is embedded in html page which display image by browsing the files in the computers hard disk... Please help me out
advantage of stored programs
advantage of stored programs  Which of the following is an advantage of stored programs? a) Reliability b)Reduction in operation costs c) The computers becoming general purpose D) All of the above E) None of these  
where are program instructions and data values stored
where are program instructions and data values stored  Where are program instructions and data values stored in Computer?   In Storage. Actually, whichever program and data we use in our computers are stored in Storage
GIGO Full Form
GIGO Full Form  What is Full form of GIGO?   Garbage In, Garbage Out is a Full Form of GIGO in regards simple principles followed by computers
What is hacker?
What is hacker?  What is hacker?   A Hacker is a person who used his or her expertise to gain access to other people's computers to get information illegally or do damage
Remote System OS name in JAVA - JSP-Servlet
Remote System OS name in JAVA  I need to print the different os names of the all computers in my local network. I know that with System.getProperty("os.name"), I get the os name of my computer but for the other computers, I have
Proxies
, it is advanced traffic redirection tool. It can provide you access to computers behind..., it is advanced traffic redirection tool. It can provide you access to computers behind
Computer Networking
the requirement to add more people as well more computers. Suppose you buy 5 computers... by the new 5 computers, this will save the money and resources to buy... a network in which all the computers are interconnected and share the same printer
Computer Networking
the requirement to add more people as well more computers. Suppose you buy 5 computers instead of going for a decision to buy 5 more printers, you... printer by the new 5 computers, this will save the money and resources
Question In the Network ?
currently has 25 standalone computers and five laser printers distributed... the laser printers, but the computers donā??t connect to each other. Because.... The company founder, Joe, things that all the computers should be able to communicate
computer - Swing AWT
computer  What is a Computer and why we should use it? I am new to this technologies so please let me know the benefits of using computer.   What you what to know about computers?Is it a software or hardware related
java
java  hi..i have developed a desktop application and i want it to run in other computers also which are connected through LAN.is it possible to do so??all the database must be in master computer only and all other computer must
digital communication system
digital communication system  A digital communication system capable of interconnecting, a large number of computers, terminals and other peripheral devices within a limited geographical area is called- a) LAN, B) WAN, C
Welcome to the Internet
be used for standard intercommunication and file transfer between computers... is passed by both the computers using the TCP/IP protocol. This means that the IP addresses will be assigned to both the computers. Then using the HTTP protocol

Ads