No you don't. You need to fail your class because you're irresponsible enough to forego study and unethical enough to steal someone else's work to submit as your own, which constitutes a form of fraud, which is illegal.
llaffer
2011-12-22 06:51:53 UTC
No. I don't think that you will find anyone to do your homework for you. But I can give you pseudocode so you can use that logic to create your own code.
bool firstEntry = true;
int userInput;
int smallestInput;
int oddCount= 0;
int sumOfOdds= 0;
do
prompt for a number with -8 to end program
collect userInput
if userInput not equal to -8
if number is odd
Add one to oddCount
Add value of userInput to sumOfOdds
if first entry
firstEntry = false
smallestInput = userInput
else
if userInput is smaller than smallestInput
smallestInput = userInput
while userInput is not equal to -8
calculate average of odd numbers
display smallest number and average of odd numbers
ⓘ
This content was originally posted on Y! Answers, a Q&A website that shut down in 2021.