java

Java program to find the maximum element in a HashSet

Java program to find the maximum element in a HashSet. we can either run a loop and find out the maximum or we can use the predefined method max defined in Collections.

Read
c#

C# program to find the days, hours, minutes, and seconds between two dates

Learn how to find the days, hours, minutes, and seconds between two dates in C#. This program will print the difference between two DateTime objects and print the result.

Read
c#

Find the seconds and milliseconds time difference between two time in C#

C# example program to get the time difference between two date objects in seconds and milliseconds. This program will show you how to find the time difference in seconds and milliseconds in C# easily.

Read
c#

C# program to find the sum of all numbers from 1 to n

C# program to find the sum of all numbers from 1 to n. It will take the value of n and print out the sum.

Read
c#

C# program to print the Floyd's triangle

C# program to print the Floyd's triangle. This program will take the row number as input and print the Floyd's triangle.

Read
python

Python program to get the absolute path of a file

Python program to get the absolute path of a file. os.path module provides abspath() method that can be used to find the absolute path of a file in python.

Read
python

How to find the common path in a list of paths in python

Python find the common path in a list of paths in python. Python os.path.commonpath method can be used to find the common path in a list of paths. This python example will show you how to use os.path.commonpath

Read
c#

C# program to count the total number of vowels in a string

C# program to find the count of vowels in a string.

Read
python

Python program to get the last modified time of a path

Python program to find the last modified time of a path. os.path.getmtime method can be used to find the last modified time for a given path. This program will use this method.

Read
python

Python program to get the last access time of a path

Python program to find the last access time of a path. os.path.getatime method can be used to find the last access time for a given path. This program will use this method.

Read