Visit the Ironworks Gaming Website Email the Webmaster Graphics Library Rules and Regulations Help Support Ironworks Forum with a Donation to Keep us Online - We rely totally on Donations from members Donation goal Meter

Ironworks Gaming Radio

Ironworks Gaming Forum

Go Back   Ironworks Gaming Forum > Ironworks Gaming Forums > General Discussion > General Conversation Archives (11/2000 - 01/2005)
FAQ Calendar Arcade Today's Posts Search

 
 
Thread Tools Search this Thread
Old 11-22-2002, 02:23 AM   #11
Neuromancer
Manshoon
 

Join Date: May 24, 2002
Location: Slovenia
Age: 56
Posts: 166
Quote:
Originally posted by /)eathKiller:
well you do know that Java and C++ are cousins...
Distant ones, though.
When I was in school they made me write software in Fortran77. Urgh ! Still have that moth-decay taste in my mouth when I think about it [img]smile.gif[/img]
I don't touch C++ unless there is a *really* good reason to. And I wonder what's wrong with non-programmers that (try to) manage programmers. They hear somwhere that anything can be done with c++ & they here somwhere else that xlm is a good thing. Then you have get a project for a database front-end and the STRONG reccomendation from upstairs is that we should use C++ combined with Xlm. And then ... well ... then IT'S time to go berserk [img]smile.gif[/img]

Neuro.
__________________
/* Chapter Fifteen, Elementary Necromancy. Lesson One: Correct Use of Shovel... */
Neuromancer is offline  
Old 11-22-2002, 02:53 AM   #12
LennonCook
Jack Burton
 

Join Date: November 10, 2001
Location: Bathurst & Orange, in constant flux
Age: 37
Posts: 5,452
Quote:
Originally posted by Blade:
well here i would post my code here so people could confuse themselves but it says html code error, doesn't allow parenthasis on my o well thank for the help, it works. I knew it would just coudn't figure out how to put it into code thanks.
[code] code goes here [/code]

[ 11-22-2002, 02:54 AM: Message edited by: LennonCook ]
LennonCook is offline  
Old 11-22-2002, 08:14 AM   #13
NiceWorg
Baaz Draconian
 

Join Date: January 15, 2002
Location: Vaasa, Finland
Age: 42
Posts: 772
They have much in common, but I can only handle Java, so you must know it better.
__________________
Fell in love with a country girl, morning sunshine<br />She was up from a nether world, just to bust another soul<br />[url]\"http://jarkokson.suddenlaunch.com\" target=\"_blank\">Click!</a>
NiceWorg is offline  
Old 11-22-2002, 12:36 PM   #14
Blade
Emerald Dragon
 

Join Date: March 12, 2001
Location: spokane wa usa
Age: 40
Posts: 926
Ok here is my code, it's probably not effecient. It doesn't output what i want exactly the way i wanted it to. But it meets the teachers requirements so [img]tongue.gif[/img] here it is. Feel free to confuse yourself with it

code:
 //This program was written by Chris Nance
//It was last modified on 11/21/02

#include <iostream>
#include <cstring>
#include <fstream>

using namespace std;
//this function reverses the order of the charecters in the string
void reverse(char input[],char output[])
{
int len= strlen(input)-1;
for( int i = 0; input[i] != '\0' && i <= len; i++)
{
output[len - i] = input[i];
}
output[++len] = '\0';
}

//this fuction checks the two strings created from reverse to see if they are equal
bool pal1(char input[])
{
char misarray[40];
reverse(input,misarray);
return (stricmp(misarray, input)==0);

}
//this funcion checks the first and last place of a string to see if they are the same.
bool pal2 (char input[], int len)
{
bool result;
int i;
result = true;
for (i = 0; i < len; i++)
{
if (input[i] != input[ len - i])
{
result = false;
}
}
return result;
}
/*this is the main funcion, it opens and outputs to/from files,
and sends the strings into the functions to tell wheather it is a palindrome or not*/
void main()
{
ifstream input;
ofstream output;
char strinput[40];
int len;

input.open ("strings.txt");
if ( input.fail())
{
cout << "error opening input file";
exit(0);
}
output.open ("palindrome.txt");
if ( output.fail())
{
cout << "Error making ouput file";
exit(0);
}

while ( !input.fail())
{
input.getline(strinput, 40);
len = strlen(strinput);
if (pal1(strinput))
output << strinput << endl;
if (pal2(strinput, len))
output << "from the second function" << endl;
output << strinput << endl;
}

input.close();
output.close();
}
[/QUOTE]
__________________
<br /><br />All blades cut, be they made from metal or wood, but the sharpest and deadliest blade is the one of knowledge, and that is the least used.<br />An Archmage of the HADB
Blade is offline  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Another Video Card Question becomes Antivirus Question!!! Bahamut General Conversation Archives (11/2000 - 01/2005) 19 12-27-2003 11:40 PM
One BIZZZARE question and one normal everyday question Sythe Baldurs Gate II: Shadows of Amn & Throne of Bhaal 3 09-10-2002 02:44 AM
Early ch6 question - poss spoiler info in question... Fljotsdale Baldurs Gate II Archives 5 03-18-2001 12:33 AM
Dragon spire crystal question + question about Giant killing for the warriorguild Malakez Wizards & Warriors Forum 4 02-20-2001 03:52 PM
spell lvl question, buying spells question, and role ascension question Paupa Wizards & Warriors Forum 1 12-31-2000 04:59 PM


All times are GMT -4. The time now is 02:11 AM.


Powered by vBulletin® Version 3.8.3
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
©2024 Ironworks Gaming & ©2024 The Great Escape Studios TM - All Rights Reserved