TIP: Click on subject to list as thread! ANSI
echo: c_plusplus
to: STEVEN READ
from: EDWARD RUTLEDGE
date: 1997-06-24 01:27:00
subject: Part 2 of 3?

				cout << "\nPlease input the Julian date:  "; 
				cin >> temp; 
				} 
			to_gregorian ( temp, month_, day_, year_ ); 
			if ( month_dsp > 1 ) 
				cout << month_1 [ month_dsp ] [ month_ - 1 ] 
				     << "/" << day_ << "/" << year_ 
				     << endl; 
			else 
				cout << month_1 [ month_dsp ] [ month_ - 1 ] 
				     << " " << day_ << ", " << year_ << endl; 
			break; 
		case '2': 
		case 'D': 
		case 'd': 
		case 'A': 
		case 'a': 
			if ( argc >= 6 && argc <= 7 ) 
				{ 
				temp = to_julian ( tempx [ 2 ], 
				       tempx [ 3 ], tempx [ 4 ] ); 
				days = tempx [ 5 ]; 
				if ( argc == 7 ) 
					{ 
					if ( tempx [ 6 ] >= 0 
					&& tempx [ 6 ] <= 2 ) 
						{ 
						month_dsp = tempx [ 6 ]; 
						} 
					else 
						{ 
						month_dsp = 0; 
						} 
					} 
				else 
					{ 
					month_dsp = 0; 
					} 
				} 
			else 
				{ 
				cout << '\n'; 
				month_dsp = 0; 
				temp = to_julian ( ); 
				cout << "Input number of days of delay = "; 
				cin >> days; 
				} 
			if ( days < 0 ) 
				{ 
				cout << "Error 167:48\n" 
				<< "Unable to handle negative days!\n"; 
				exit ( 110 ); 
				} 
			xtemp = Days_in_year ( temp ); 
			if ( ( days + temp % 1000 ) > xtemp ) 
				{ 
				year_ = temp / 1000; 
				days += temp % 1000; 
				while ( days >= xtemp ) 
					{ 
					days -= xtemp; 
					year_++; 
					xtemp = Days_in_year ( year_ ); 
					} 
				temp = year_; 
				temp *= 1000; 
				temp += days; 
				} 
			else 
				temp += days; 
			to_gregorian ( temp, month_, day_, year_ ); 
			if ( month_dsp > 1 ) 
				cout << month_1 [ month_dsp ] [ month_ - 1 ] 
				     << "/" << day_ << "/" << year_ << endl; 
			else 
				cout << month_1 [ month_dsp ] [ month_ - 1 ] 
				     << " " << day_ << ", " << year_ << endl; 
			break; 
		case '3': 
		case 'b': 
		case 'B': 
		case 'N': 
		case 'n': 
			if ( argc == 8 ) 
				{ 
				start_ = to_julian ( tempx [ 2 ], 
				       tempx [ 3 ], tempx [ 4 ] ); 
				end_ = to_julian ( tempx [ 5 ], 
				       tempx [ 6 ], tempx [ 7 ] ); 
				} 
			else 
				{ 
				cout << "\nStart Date\n"; 
				start_ = to_julian ( ); 
				cout << "End Date\n"; 
				end_ = to_julian ( ); 
				} 
			cout << Days_Between ( start_, end_ ) 
			     << " Days.\n"; 
			break; 
		} 
		exit ( argc - 1 ); 
	} 
 
--- 
 * OFFLINE 1.58 
--- WILDMAIL!/WC v4.12 
---------------
* Origin: Star Tech Diamond Bar, CA 909-396-4227 714-257-1175 (1:218/801.0)

SOURCE: echomail via exec-pc

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.