Off-topic Talk Where overpaid, underworked S2000 owners waste the worst part of their days before the drive home. This forum is for general chit chat and discussions not covered by the other off-topic forums.

Can all the computer programmers please read!!! I have a question for you.

Thread Tools
 
Old Jan 30, 2002 | 08:12 AM
  #11  
Shinji's Avatar
Thread Starter
Registered User
 
Joined: Jul 2001
Posts: 1,985
Likes: 0
Default

Off-topic at its best.
Reply
Old Jan 30, 2002 | 10:58 AM
  #12  
krhorrocks's Avatar
Registered User
 
Joined: Feb 2001
Posts: 627
Likes: 0
From: Seattle, WA
Default

geeks unite! Here it is in C#.

using System;
namespace RSXTypeR
{
class FarenheitToCelsiusConverterApp
{
static void Main(string[] args)
{
Console.WriteLine("Enter temp in F :");
double f = double.Parse(Console.ReadLine());
double c = (5d/9d) * (f-32);
Console.WriteLine("Celsius temperature is {0}",c);
Console.ReadLine();
}
}
}
Reply
Old Jan 30, 2002 | 04:28 PM
  #13  
davepk's Avatar
Registered User
Gold Member (Premium)
20 Year Member
 
Joined: Oct 2000
Posts: 1,664
Likes: 0
From: Santa Cruz, CA
Default

[QUOTE]Originally posted by RSXTypeR
[B]I didn't really expect a reply or answer from someone.
Reply
Old Jan 30, 2002 | 04:37 PM
  #14  
Luder94's Avatar
Moderator
25 Year Member
Liked
Loved
Community Favorite
 
Joined: Oct 2000
Posts: 12,904
Likes: 93
From: Big Box suburb, IL
Default

,,,ahhhhh memories that bring a tear to my eye!!! Hey RSX, what book are you using? Is it a Deitel "C++, How To Program book"?
Reply
Old Jan 30, 2002 | 05:08 PM
  #15  
Shinji's Avatar
Thread Starter
Registered User
 
Joined: Jul 2001
Posts: 1,985
Likes: 0
Default

My book is "Computing using C++ and Object Technology," I know this is a kiddie book. Luder94, I'm not using the Dietel book, but I have it. Didn't get the chance to read it yet. If my source code compile in telnet/unix, does that mean I can run it with no problems with real numbers, etc.? I love C++!!! Another question for the computer minded.

Question: When I start the source code I always use #include <iostream.h> and I don't need to attach any header files along. But what if I use #include "textlib.h". Does that mean I have to attach textlib.h into my folder before I can compile it correctly? I know what <> mean but what's " "?
Reply
Old Jan 30, 2002 | 06:47 PM
  #16  
SpEeDxXxRaCeR's Avatar
Registered User
 
Joined: Oct 2001
Posts: 3,230
Likes: 0
From: Sugar Land
Default

[QUOTE]Originally posted by RSXTypeR
[B]My book is "Computing using C++ and Object Technology," I know this is a kiddie book.
Reply
Old Jan 30, 2002 | 08:16 PM
  #17  
moonpie's Avatar
Registered User
 
Joined: Oct 2001
Posts: 1,611
Likes: 0
From: Melbourne
Default

Here it is in perl:

#!/usr/bin/perl
print "Enter the temperature in Fahrenheitn";
chomp($fah = <STDIN>);
$cel = ($fah - 32) * (5/9);
print "The temperature in Celcius is $celn";
Reply
Old Jan 30, 2002 | 08:38 PM
  #18  
hyper's Avatar
Registered User
 
Joined: Nov 2001
Posts: 6,241
Likes: 0
From: Toronto
Default

LOL ... how about Javascript and HTML ?



[CODE]

<html>

<head>

<script language="javascript">

/* this function accepts an input expressed as farenheit temperature and

converts the input into temperature expressed in celsius.
Reply
Old Jan 30, 2002 | 08:45 PM
  #19  
YoungS2K's Avatar
Registered User
20 Year Member
 
Joined: Oct 2000
Posts: 1,529
Likes: 0
From: Chicago
Default

NERDS
Reply
Old Jan 30, 2002 | 10:15 PM
  #20  
Shinji's Avatar
Thread Starter
Registered User
 
Joined: Jul 2001
Posts: 1,985
Likes: 0
Default

Because of the "abstract" language used in this thread, I will have to lock this thread to prevent further source code spawnings that will/might endanger the goal of s2ki.com as a "car enthusiast" board. J/K

P.S. If I copied what some of you wrote as an answer to my program...I would probably be expelled from my university by now! HAHA
Reply



All times are GMT -8. The time now is 03:54 AM.