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
Swapping two numbers
Tju [1.3M]

Answer:

Swapping two numbers means exchange the values of two variables with each other.

8 0
3 years ago
Transparency is an important concept in policies related to the handling and use of customer data. Organizations should be trans
Tpy6a [65]

Answer: (C) Response controls

Explanation:

  According to the given question, the response control is not the necessary element while handling the users or customer data as compared to all the other given options that is individual participation, data minimization and the purpose specification.

  • The response control is basically used for exchange the data or any information in an organization but the main disadvantage is that they share all the response and information as they not wait for the request from the users.
  • The all the three other given options expect response control are the important element for handling the customer data as it helps in maintaining the Personal information.  

 Therefore, Option (C) is correct answer.  

6 0
3 years ago
What tool is included with windows 8 that will help you connect to the directaccess server when you have problems and can be use
Elina [12.6K]
None that I know. Many third party apps.
4 0
3 years ago
Four possible skills a person could have
cluponka [151]

Answer:

Active listening skills.

Genuine interest in others.

Flexibility.

Good judgment.

Explanation:

4 0
3 years ago
Assume that minutes is an int variable whose value is 0 or positive. Write an expression whose value is "undercooked" or "soft-b
e-lub [12.9K]

Answer:

import java.util.Scanner;

public class Solution {

   public static void main(String args[]) {

     Scanner scan = new Scanner(System.in);

     System.out.println("Enter your minute:");

     int minute = scan.nextInt();

     

     switch(minute){

         case 0:

         case 1:

             System.out.println("undercooked");

             break;

         case 2:

         case 3:

         case 4:

             System.out.println("soft-boiled");

             break;

         case 5:

         case 6:

         case 7:

             System.out.println("medium-boiled");

             break;

         case 8:

         case 9:

         case 10:

         case 11:

             System.out.println("hard-boiled");

             break;

         case 12:

             System.out.println("overcooked");

             break;

         default:

             if(minute > 12){

               System.out.println("overcooked");

             } else if (minute < 0){

                 System.out.println("Enter a valid minute.");

             }            

     }

   }

}

Explanation:

The first line is the import statement, which import the Scanner class for receiving user input. The next line is the class declaration which is named Solution.

The Scanner object is declared and assigned as scan. Then a prompt is displayed to the user asking the user to enter the minute. The user input is stored as minute.

Switch statement is use to categorize the user input. If the user enter 0-1, an output of undercooked is displayed. If the user enter 2-4, an output of soft-boiled is displayed. If the user enter 5-7, an output of medium-boiled is displayed. If the user enter 12 or any number above 12, an output of overcooked is displayed. Again, the user enter a number less than zero, an error message is displayed telling the user to enter a valid number.

4 0
3 years ago
Other questions:
  • After correctly configuring a new wireless enabled thermostat to control the temperature of the company's meeting room, Joe, a n
    6·1 answer
  • Which of the following correctly describes the function of an IP address
    13·1 answer
  • Host A is sending Host B a large le over a TCP connection. Assume Host B has no data to send Host A. Host B will not send acknow
    14·1 answer
  • The _________ in Java is passed by value but ______ is passedby reference.
    5·1 answer
  • Find a 95% confidence interval for the mean failure pressure for this type of roof panel.The article "Wind-Uplift Capacity of Re
    7·1 answer
  • How are logical operators used?
    14·1 answer
  • Peace is a fruit of the Spirit that comes from _______ .
    11·1 answer
  • [1] Please find all the candidate keys and the primary key (or composite primary key) Candidate Key: _______________________ Pri
    6·1 answer
  • File-sharing utilities and client-to-client communication applications can provide the capability to share files with other user
    14·1 answer
  • Algorithm to calculate the area of a square.​
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!