Skip to content

Tag Archives: date-time-program

Given a positive integer D and a string M representing the day and the month of a leap year, the task is to find the… Read More
Given a string S representing a time in 24 hours format, with ‘_’ placed at positions of some digits, the task is to find the… Read More
Given an array arr[][2] consisting of N pair of strings representing the starting and ending time (in 12 hours format) and a string P which… Read More
Given an array arr[] consisting of N strings and an array Query[] consisting of Q queries. Each string in arrays arr[] and Query[] is of… Read More
Given a Unix Timestamp T (in seconds) for a given point in time, the task is to convert it to human-readable format (DD/MM/YYYY HH:MM:SS) Example:… Read More
Given a date in the form of a string, the task is to write a Java Program to get the day, month, and year from… Read More
You are given a time T in 24-hour format (hh:mm) and a positive integer K, you have to tell the time after K minutes in… Read More
Given a generic digital clock, having h number of hours and m number of minutes, the task is to find how many times the clock… Read More
Sorting a multidimensional array by element containing date. Use the usort() function to sort the array. The usort() function is PHP builtin function that sorts… Read More
Given an integer n (in seconds), convert it into hours, minutes and seconds. Examples: Input : 12345 Output : 3:25:45 Input : 3600 Output :… Read More
Write a Python program to find the day of the week for any particular date in the past or future. Let the input be in… Read More
Given an integer n which is the number of hours, the task is to convert it into minutes and seconds.Examples:   Input: 5 Output: Minutes = 300,… Read More
Given birth date in y/m/d format, write a Python program to find the present age in years. Examples: Input : 1997/2/3 Output : 21 years… Read More
Given two dates, Write a Python program to find the total number of days between them. Examples:   Input : dt1 = 13/12/2018, dt2 = 25/2/2019 Output… Read More
Problem: Convert timestamp to readable date/time in PHP Solution: This can be achieved with the help of date() function, which is an inbuilt function in… Read More