Write a program that prints the day number of the year

Assignment Help C/C++ Programming
Reference no: EM132081244

Need this program in Java

Develop (using C++ or Java language) the software application described below.

Write a program that prints the day number of the year, given the date is in the form month-day-year.

For example, if the input is 1-1-09, the day number is 1; if the input is 12-25-09, the day number is 359. The program should check for a leap year. A year is a leap year if it is divisible by 4 but not divisible by 100.

For example, 1992 and 2008 are divisible by 4 but not by 100. A year that is divisible by 100 is a leap year if it is also divisible by 400.

For example 1600 and 2000 are divisible by 400, so they are leap years. However, 1800 is not a leap year because 1800 is not divisible by 400.

Reference no: EM132081244

Questions Cloud

Discuss the potential issues that a manager confronts : Discuss the potential issues that a manager confronts when he/she needs to incur more direct labor cost in order to comply with the production deadlines
Expected return on the market : One-year Treasury securities are yielding 4% and the expected return on the market is 10%.
What is the equity premium : The expected return on the market portfolio is 12%, and the relevant risk-free rate is 4.2%. What is the equity premium?
Record the transaction on the books of the debt service fund : On July 1, 2012, a current refunding took place in which $6,000,000 in new general obligation bonds were issued. Record the transaction on the books
Write a program that prints the day number of the year : Write a program that prints the day number of the year, given the date is in the form month-day-year.
Three ethical philosophical challenges to this position : Describe ethical relativism and at least three ethical philosophical challenges to this position.
Create php web pages and database for the given requirements : The median occured letter is calculated from the table. this median occured letter is used as group separator to divide the whole data into groups.
Prepare tabular summary of effects of alternative actions : Prepare a tabular summary of the effects of the alternative actions on the components of stockholders' equity, outstanding shares, and par value per share
The domestic and global marketplace : The controllable and uncontrollable factors that face marketers in both the domestic and global marketplace.

Reviews

Write a Review

C/C++ Programming Questions & Answers

  Write a program that will read in 2 test score.

Write a program that will read in 2 test score. The instructor has decided to give each student 10 bonus point on each test. Print out each test score and the total after the bonus, the print the total number of points earned on the tests.

  Write a program to create 100 real random numbers

Write a program to create 100 real random numbers and store it into a 1-D array. Find the value 1413 from the stored data and print out the value 1413 and the index of the array to the screen

  What the final value of the variable sum e was

Write a program that asks the user to enter an integer dollar amount between 1 and 5,000. Your program should display the corresponding class description using the following table. Write the program so that it executes until the user inputs some v..

  Program that can serve as a simple calculator

Write a program that can serve as a simple calculator. This calculator keeps track of a single number (of type double) that is called result and that starts out as 0.0. Each cycle allows the user to repeatedly add, subtract, multiply, or divide by..

  Assume we have an array named $students

Assume we have an array named $students. Each entry in the array contains a student's full name (e.g. "Jane Smith"). Write the PHP code needed to display all students (in the array) whose first name starts with the letter "J".

  Write table_avg function to find the average of an array.

Write table_print function to print out a table of size. Print output on one line.table_print(array, size);

  Write a c matrix multiplication program which you can

write a c matrix multiplication program which you can instrument to monitor and measure execution time as a function of

  Dynamic character arrays

Dynamic character arrays str and add contain strings. Write a function append that uses str and add as arguments and appends add to the end of str. Write a main program that illustrates the use of function append to concatenate five strings.

  While loop that allows the user to continue entering

This code should include a while loop that allows the user to continue entering employees as long as they want to continue:int main(){Real payrate,hours, gross,again;

  Cashregister class that can be used with the retailitem clas

Write a CashRegister class that can be used with the RetailItem class that you wrote in Part 1. The CashRegister class should simulate the sale of a retail item. It should have a constructor that accepts a RetailItem object as an argument.

  Evaluate its employees four times a year at the end of year

The data will be validated and saved to an output file,"datainput" . this program will use five arrays to grater manupliate and store the data.

  Determines the access privillege of a derived class

The base class access specifier determines the access privillege of a derived class to its base class

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd