output in a single line
- From: pande_vineet@xxxxxxxxxxx (Vineet Pande)
- Date: Wed, 25 May 2005 08:59:49 +0000
Hi I tried the following script
#!/usr/bin/perl use warnings; use strict; print "Currency converter\n\nPlease enter the exchange rate: "; our $rupee_c1 = <STDIN>; print "Please enter the Amount in Rupees: "; our $rupee = <STDIN>; print "$rupee rupees are ", ($rupee/$rupee_c1), " Euros\n";
when i execute this, i get
Currency converter
Please enter the exchange rate: 56 Please enter the Amount in Rupees: 560 560 rupees are 10 Euros I AM NOT ABLE TO UNDERSTAND WHY 560 IS FOLLOWED BY RUPEES ARE 10 EUROS IN THE NEXT LINE. IS IT THE FAULT OF print "$rupee..........BECAUSE WHEN I SAY PRINT "560 ...., INSTEAD OF VARIABLE NAME, I GET THE OUTPUT IN A SINGLE LINE.
Any help appreciated cheers vineet
"The future belongs to those who believe in the beauty of their dreams" -Eleanor Roosevelt
_________________________________________________________________
Express yourself instantly with MSN Messenger! Download today it's FREE! http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/
.
- Follow-Ups:
- RE: output in a single line
- From: Manav Mathur
- I want to write a perl script to call several functions in a COM component on MSWin32.
- From: J aperlh
- RE: output in a single line
- Prev by Date: Re: Can't use subscript in angle brackets
- Next by Date: I want to write a perl script to call several functions in a COM component on MSWin32.
- Previous by thread: string, worlds
- Next by thread: I want to write a perl script to call several functions in a COM component on MSWin32.
- Index(es):
Relevant Pages
|