AYUSH MISHRA has Published 134 Articles

Calculating the Area of a Triangle Using Heron’s Formula in C++

AYUSH MISHRA

AYUSH MISHRA

Updated on 31-Dec-2024 21:57:01

5K+ Views

Problem Description We are given the three sides of a triangle, and we have to calculate the area of the triangle using Heron's formula. In this article, we are going to discuss how we can calculate the area of a triangle using Heron's Formula in C++. Heron's Formula The ... Read More

How to Filter Object by Values in Lodash?

AYUSH MISHRA

AYUSH MISHRA

Updated on 31-Dec-2024 10:36:43

5K+ Views

Sometimes we are given an object and we want to extract only the key-value pairs that meet certain criteria. In this article, we are going to discuss how we can filter objects by values in Lodash. Prerequisite Lodash: Lodash is a popular JavaScript library ... Read More

C++ Program to Subtract Two Numbers

AYUSH MISHRA

AYUSH MISHRA

Updated on 30-Dec-2024 19:22:43

16K+ Views

Problem Description In this problem, we are given two numbers and we have to find the value obtained after subtracting one number from another. In this article, we are going to learn how we can subtract two numbers in C++ using different approaches. Example 1 ... Read More

Missing Number in an array in O(1) Time Complexity

AYUSH MISHRA

AYUSH MISHRA

Updated on 30-Dec-2024 19:22:27

5K+ Views

Problem Description We are given an array that contains numbers from 1 to n, and one number is missing between the given numbers from 1 to n. We have to return the missing number in O(1) time complexity. In this problem, we are going to discuss how we can find ... Read More

How to Filter Object by Keys in Lodash?

AYUSH MISHRA

AYUSH MISHRA

Updated on 30-Dec-2024 09:31:39

6K+ Views

Sometimes while working with objects in JavaScript we want to filter objects based on keys. We can easily do this by using Lodash, a popular JavaScript library that provides several inbuilt functions to achieve this easily. In this article, we are going to discuss how we can Filter Objects by ... Read More

How to Get the Beginning and End of the Day with MomentJS?

AYUSH MISHRA

AYUSH MISHRA

Updated on 30-Dec-2024 09:14:01

7K+ Views

Sometimes, we need to find the beginning and end of the day using MomentJS. This functionality has different real-life applications, such as filtering data within a day’s range, generating daily reports, and scheduling tasks at specific times. In this article, we will discuss how to find the beginning and end ... Read More

How to Copy a Tensor in PyTorch?

AYUSH MISHRA

AYUSH MISHRA

Updated on 27-Dec-2024 15:14:04

9K+ Views

PyTorch is a very popular Python library used in machine learning. This library is developed by Facebook AI. This library provides robust tools for deep learning, neural networks, and tensor computations. Below are different approaches to Copying a Tensor in PyTorch. Using clone() function ... Read More

How to Check If Two Arrays are Equal in PHP?

AYUSH MISHRA

AYUSH MISHRA

Updated on 27-Dec-2024 15:11:08

5K+ Views

Problem Description Sometimes we need to compare two arrays in PHP to check if they are equal. Talking about equality, it means that the arrays have the same elements, in the same order, or even that their data types match. In this article, we will discuss how we can check ... Read More

How to Insert Multiple Elements at Given Positions in a Vector?

AYUSH MISHRA

AYUSH MISHRA

Updated on 24-Dec-2024 13:22:09

6K+ Views

What is a Vector in C++?A vector is a dynamic array as the size of the vector changes during the program's execution. If we insert more elements in the vector it expands its size and if we remove elements from the vector it shrinks in size. A vector is part ... Read More

How to convert MomentJS Date to Users Local Timezone?

AYUSH MISHRA

AYUSH MISHRA

Updated on 24-Dec-2024 10:08:08

6K+ Views

Sometimes, when doing a project for a specific organization in a particular country, we need to convert it into the users' local timezone. In this article, we are going to learn how to convert a date to a user's local timezone using moment.js. Prerequisite ... Read More

Previous 1 ... 7 8 9 10 11 ... 14 Next
Advertisements