How Software Gets Done  


(No Login on Secured Page)

Custom Software Buyers
Request new bids
Search Coders
My Account
 
My Buyer 'To Do' List
 
My bid requests
  My escrow account
 
My General Info
 
Help for Buyers
Articles for Buyers
Latest News
 

Custom Software Coders

Newest open work
Browse all work
Search all work
My Account
 
My Coder 'To Do' List
 
My bids
 
My General Info
  My credit account
 
Help for Coders
Articles for Coders
Latest News
 

Affiliates

My account
 
My pipeline
 
My credit account
 
Help for Affiliates
Latest News
 
Newest Open Bid Requests.
Email function to find the body
By A. Walter on Mar 8
Max Bid: Open to fair suggestions


Application GUI FaceLift Needed!
By Rusty on Mar 8
Max Bid: Open to fair suggestions


Nested classes and linked lists, template and head ...
By Ogreswarlock on Mar 8
Max Bid: $25


graphics 3
By mojama on Mar 7
Max Bid: $30


access database for ballot box entries
By spsilver on Mar 7
Max Bid: Open to fair suggestions


PayPal Code Generator 2.0
By rdjdalton on Mar 7
Max Bid: Open to fair suggestions

(Screen Shot)

Click here to put this ticker on your own site

Open Work Categories.
Database 
(147 open)
   Access 
(70 open)
   MySQL 
(75 open)
   Oracle 
(9 open)
   SQL Server 
(47 open)
   Other DB 
(25 open)
Documentation / Tech Writing 
(21 open)
Game Development 
(27 open)
Graphics / Art / Music 
(51 open)
   Graphics 
(58 open)
     3d Animation 
(21 open)
   Art (Misc.) 
(19 open)
   Music 
(6 open)
   3d Modeling 
(12 open)
Language Specific 
(94 open)
   ASP 
(50 open)
   C# 
(36 open)
   C++ / C 
(99 open)
   Cold Fusion 
(5 open)
   Delphi 
(40 open)
   Java 
(51 open)
   Perl 
(32 open)
   PHP 
(82 open)
   XML/XSL 
(17 open)
   Visual Basic 
(154 open)
   Visual Basic .Net 
(57 open)
   Other 
(44 open)
Misc 
(43 open)
   CAD 
(5 open)
MultiMedia 
(31 open)
Network 
(37 open)
   Network Design 
(8 open)
   Network Implementation 
(16 open)
Platforms 
(65 open)
   Windows 
(154 open)
     MS Exchange 
(6 open)
     MS Office 
(15 open)
     Other 
(13 open)
   Internet Browser 
(50 open)
   Linux 
(39 open)
   UNIX 
(32 open)
   Hand Held/PDA Programming 
(14 open)
Requirements 
(12 open)
Security 
(30 open)
Testing / Quality Assurance 
(12 open)
Web 
(148 open)
   Page Design 
(63 open)
   Flash 
(50 open)
   Web Services 
(57 open)
   Web (Other) 
(63 open)
Training 
(8 open)
   Computer Based 
(7 open)
 
Other
 
Other Sites

Download the free Rent A Coder IE toolbar!
 
Show Bid Request

random number generator
Bid Request Id: 4302
Bookmark in my 'To Do' list
Posted by: nothing (3 ratings)
(Software buyer rating 10)
(Cancellation Ratio: 25%)
Posted: Oct 30, 2001
5:08:05 AM EDT
Bidding Closes: Nov 13, 2001
5:08:53 AM EDT
Viewed (by coders): 222 times
Phase:
100% of work was accepted by buyer. Coder account has been credited.
Max Accepted Bid: Bidding is closed
Project Type: Personal Project / Homework Help
Bidding Type: Open Auction
Categories: C++ / C, UNIX
Enter chat room for this bid request
(0 active users at Mar 8, 2003 4:52:33 AM EDT)

Description:
Problem:
Write a program that generates simple arithmetic questions using the random number generator. The program prints out the question on the terminal and asks the user to input the answer. The program then waits a fixed time for the answer to be entered, prints out the correctness of the answer provided and the correct answer if it was wrong (or a message indicating the time ran out) on standard output and then moves on to the next question.

Method:
The main function will set up a loop, generate a question within the loop. The questions have only two operands. The operators including +, -, * and / are also to be random generated. The loop stops when the user sends interrupt signals (e.g. ctrl-C). The program then print out statistics such as how many questions have been attempted, and what is the percentage of the questions that were not answered.

Here is how the program should go:

loop (until interrupt signal is received)
print the question
fork
in the child:
read the answer, output the result, exit
in the parent process:
set a flag to indicate no answer
sleep for required number of seconds
if still no answer
kill the child
print out that time's up
flush any pending characters from stdin *
wait for the child (to avoid zombies)
end of the loop
clean up


If the child terminates before the sleep is completed, it sends a signal called SIGCHLD to the parent. This signal interrupts the parent and, provided the parent has an interrupt handler for it, enables the parent to change the value of the (global) flag to indicate that an answer has been received.

The program should accept one command line argument: the wait time per question. (No error checking is required in this assignment.)


Deliverables:
Complete and fully-functional working program(s) in executable form as well as complete source code of all work done.


Special Conditions / Other:
i need within 1 day n must run under unix


Remember that contacting the other party outside of the site (by email, phone, etc.) on all business projects < $500 (before the buyer's money is escrowed) is a violation of both the software buyer and seller agreements. We monitor all site activity for such violations and can instantly expel transgressers on the spot, so we thank you in advance for your cooperation. If you notice a violation please help out the site and report it. Thanks for your help.
 
Bidding/Comments:
All monetary amounts on the site are in United States dollars.
Rent a Coder is a closed auction, so coders can only see their own bids and comments. Buyers can view every posting made on their bid requests.

See all rejected bids (and all comments)
Name   Bid Amount 
 
Date   Coder Rating  
BeNZOiT
(7 ratings)
in Venetia, Pennsylvania
United States
Bid id: 41,925
 
$20 (USD) Oct 30, 2001
7:14:49 AM EDT
 9.85
(Excellent)
   
 

This bid was accepted by the buyer!
BeNZOiT
(7 ratings)
in Venetia, Pennsylvania
United States
Bid id: 42,095
 
$20 (USD) Oct 30, 2001
11:56:58 AM EDT
 9.85
(Excellent)
   
I can write this program for you with no trouble, I am very experenced with the using of real time. Here is an example of 'stop watch' code I have that calulates time to the neareast... I think nano second on any computer. // File stopwatch.hpp #ifndef STOPWATCH_HPP #define STOPWATCH_HPP #include <iostream> #include <ctime> class StopWatch { public : StopWatch (); void reset (); void start (); void stop (); double value () const; private : clock_t begin; clock_t end; bool run; }; ostream& operator<< (ostream&, StopWatch const&); #endif #include <iostream> #include <ctime> #include 'stopwatch.hpp' StopWatch::StopWatch() { run = false; end = begin = clock(); } void StopWatch::reset() { end = begin = clock(); } void StopWatch::start() { if (!run) { begin = clock(); run = true; } } void StopWatch::stop() { if (run) { end = clock(); run = false; } } double StopWatch::value() const { return run ? (clock()-begin)/double(CLOCKS_PER_SEC) : (end-begin)/double(CLOCKS_PER_SEC); } ostream& operator<< (ostream& os, StopWatch const& sw) { ios::streamsize p(os.precision(2)); ios::fmtflags f(os.setf(ios::fixed, ios::floatfield)); os << sw.value(); os.precision(p); os.flags(f); return os; } While I would not use this code for your program, it is an abple of my ability to use it.
 
 
 
 
  See 5 private reply(ies)
to/from BeNZOiT.
 




Quick Search
 

 Advanced Search
Newest Open Work
Latest News

 
Credentials


 

 
Rent A Coder upholds the rigorous business practices required to be both a BBB member and Square Trade vendor.
  • All customer issues addressed within 2 days
  • Openly disclosed pricing and return policies
  • Participation in mediation at buyer request
  • Superior selling track record
This site is verified through its parent company, Exhedra Solutions, Inc.
 

Rent A Coder Top Coders.


Anuj Gakhar
Rated a 9.98 on 83 jobs 
Codman
Rated a 9.97 on 129 jobs 
teleCODERS
Rated a 9.93 on 67 jobs 
Securenext
Rated a 9.98 on 75 jobs 
Michael Sharp
Rated a 9.98 on 153 jobs 
RNA
Rated a 9.92 on 31 jobs 
Buddies
Rated a 9.84 on 60 jobs 
markesh
Rated a 10 on 21 jobs 
Andrei Remenchuk
Rated a 10 on 10 jobs 
PSergei
Rated a 9.72 on 57 jobs 

See all top coders...

(What makes a top coder?)

Top Exam Scorers
 
Other
Rent A Coder is PayPal verified through it's parent company, Exhedra Solutions, Inc.

Created in partnership with:

 


Affiliate Sites



Latest News | About Us | Kudos | Feedback/Contact    Affiliates | Advertise    Privacy | Legal

Copyright © 2001, Exhedra Solutions, Inc. All rights reserved.
By using this site you agree to its Terms and Conditions.
"Rent A Coder" (tm), "Safe Project Escrow" (tm) and "How Software Gets Done" (tm)
are trademarks of Exhedra Solutions, Inc.