1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Alex73 [517]
3 years ago
12

To create a DateTime object that represents a due date that's 90 days after the current date, you use the following code:

Computers and Technology
1 answer:
Helen [10]3 years ago
4 0

If $due_date contains a DateTime object, $due_date_diff will contain  

c. a DateInterval object

Explanation:

  • The DateInterval class ¶  represents a date interval.
  • A date interval stores either a fixed amount of time (in years, months, days, hours etc) or a relative time string in the format that DateTime's constructor supports.
  • The diff method is just as easy to use, but provides an extra piece of information: total days. This is important because when using the DateTime object to find a difference, we have a source and destination date, and therefore we can reduce the units of time into larger denominations. However, having the total number of days in between is a valuable piece of information.
  • The PHP DateTime class has three methods that work with a DateInterval object:
  1. add
  2. sub
  3. diff

Properties

  • y  :Number of years.
  • m  :Number of months.
  • d  :Number of days.
  • h  :Number of hours.
  • i  :Number of minutes.
  • s  :Number of seconds.
You might be interested in
ROM is designed for _________
Sidana [21]
Computer Instructions

ROM, or Read Only Memory is used to store instructions as it retains memory even after power loss.
6 0
3 years ago
The femur is _____.<br><br> part of a cell<br> the thigh bone<br> a hair follicle<br> a muscle
MA_775_DIABLO [31]

Its the Thigh Bone. Hope this helps. =^-^=

7 0
2 years ago
Design a database to keep data about college students, their academic advisors, the clubs they belong to, the moderators of the
alekssr [168]

Answer:

Complete design is attached below.please have a look.

Explanation:

8 0
3 years ago
Read 2 more answers
Beth’s multimedia business specializes in sound integration and editing. A New project requires video editing and the creation o
ANEK [815]

Answer:

A. Adobe illustrator

Explanation:

4 0
3 years ago
One interesting application of computers is to display graphs and bar charts. Write an application that reads five numbers betwe
Nezavi [6.7K]

Answer:

The answer to this question can be given by program that  are as follows

import java.util.*;

//import package for taking input from user.

public class Main   //define class

{

public static void main (String ag[] )   //define main function

{

 int number;

 Scanner input = new Scanner(System.in);

 for (int i = 0; i < 5; i ++)                       //loo for input.

 {

  System.out.print ("Enter a number between 1 - 30:  ");

  number = input.nextInt();          //input number by the user.

 

 }

 asterisk();           //calling function.

 }

public static void asterisk()          //defination of function.

{

    //body of function.

    int n;                   //local variable.

 for (n= 0; n <= 30; n++)                  //using loop for print asterisk

 {

 if (n !=0)

 //printf used for print value.

 System.out.printf("*", n );                  //print value.

 }

 

  for (n= 0; n <= 30; n++)         //using loop for print asterisk

  {

 if (n !=0)

 //printf used for print value.

 System.out.printf("*", n );     //print value.

 }

 

  for (n= 0; n <= 30; n++)          //using loop for print asterisk

  {

 if (n !=0)

 //printf used for print value.

 System.out.printf("*", n );          //print value.

 }

  for (n= 0; n <= 30; n++)            //using loop for print asterisk

 

 {

 if (n !=0)

 //printf used for print value.

 System.out.printf("*", n );               //print value.

 }

 

  for (n= 0; n <= 30; n++)             //using loop for print asterisk

  {

 if (n !=0)

 //printf used for print value.

 System.out.printf("*", n );             //print value.

 }

}

}

Output:

Enter a number between 1 - 30: 2

Enter a number between 1 - 30: 2

Enter a number between 1 - 30: 1  

Enter a number between 1 - 30: 3

Enter a number between 1 - 30: 4

*******************************************************************************

Explanation:

In this program we take 5 time input from the user and print the value in the form of (*) that can be explain in above output section.In that program we use printf method that is also used for print the value.

3 0
2 years ago
Other questions:
  • *asap* Name one of the similarities between Word and Excel.
    7·1 answer
  • This program will store roster and rating information for a soccer team. Coaches rate players during tryouts to ensure a balance
    7·1 answer
  • When the CSS property of position is set to ____ it moves the element relative to its original position and allows other element
    10·1 answer
  • Name the contributions of Steve Jobs and Bill Gates, with respect to technology.
    5·1 answer
  • What is the name of the technology that is typically implemented on switches to avoid Ethernet connectivity problems when the wr
    11·1 answer
  • What simple machine is most often used to lift the blinds on a window?
    8·2 answers
  • Write a program that performs the following tasks: Display a friendly greeting to the user Prompt the user for the value to conv
    13·1 answer
  • Discuss seven multimedia keys​
    8·1 answer
  • In a List of Positive Integers, Set MINIMUM to 1. For each number X in the list L, compare it to MINIMUM. If X is smaller, set M
    11·1 answer
  • Which option identifies the programming paradigm selected in thr following scenario? A student is writing a science fiction stor
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!