Octal Integer is a number system having a base of 8 and digits from 0 to 7. Int data type is taken into account to store an octal number. The usage of the Octal number system is to be discussed here − Converting decimal to Octal Converting octal to decimal. Conversion from a Decimal number system to an Octal Number system Basics of Conversion To convert any decimal number into its equivalent octal number: Keep dividing the decimal number by the base of the octal number system which is 8 till the quotient 0 is received. Remember ... Read More
Introduction Food drying is an ancient technique that has been used for centuries to preserve food. It involves removing the moisture from the food, which in turn, prevents the growth of bacteria and mold. Drying food not only extends the shelf life of food but also helps to retain the nutritional value and flavour of food Explained below are the purpose of food drying, methods of food drying, and the pros and cons of drying food. Purpose of Food Drying Food drying serves the primary purpose of extending the shelf life of food. When moisture is removed from food, bacteria, ... Read More
Reversing a linked list means arranging all the nodes of the linked list in the opposite manner as they were present earlier or moving the elements present at the last of the linked list towards the head and head nodes towards the tail. Alternate K nodes reversing means reversing the first k elements and then keeping the next k elements the same and again reversing the next k elements and so on. We will see the codes with the different approaches and explanations for each of them. For example If the given linked list is the: 1 ... Read More
A linked list is a linear data structure that consists of interconnected nodes. Reversing a linked list means changing the order of all its elements. Reversing a linked list in groups of a given size means, we are given a number and we will reverse the first given number of elements, and then for the next set we will reverse the elements. We will see the proper code with implementation. Examples Given linked list: 1 -> 2 -> 3 -> 4 -> 5 -> 6 -> 7 -> 8 -> null Given number: 3 Output: 3 -> 2 -> ... Read More
Right rotation of an array means to rotate the elements of the array to their right side by a given number of times and for the number which are present at the edge they will move to the first index in their right rotation by assuming an array in a cycle form. We will implement a proper code to implement the algorithm with an explanation. Example Let us assume we have given array as [1, 2, 3, 4, 5, 6, 7, 8, 9] The number of right rotations of the array is 3 Output: 7 8 9 1 2 ... Read More
An array is a linear data structure used to store the different types of objects and we are given an array of size n and an integer k (where k is the number by which we will rotate an array). We will rotate the array by k elements and then return the rotated array. Rotation means we have to traverse the array from the given kth element and shift all the integers by one and we have to shift each element by 1 till the kth element came to position ‘0’ or we can say at index number ‘0’. Note ... Read More
Introduction Drying is an essential unit operation in bioprocess engineering that involves the removal of moisture or water from a product. In bioprocessing, drying is a critical step because it helps to preserve the quality and stability of the product, prevent microbial growth, and enhance shelf-life. Addressed below are the mechanism of drying in bioprocesses, including the different types of drying, and their applications in various industries. Drying Mechanisms The drying mechanism involves the transfer of moisture from a product to the surrounding environment through a process known as diffusion. Diffusion occurs as a result of the concentration gradient between ... Read More
The linked list is a linear data structure that consists of nodes, and each node is stored in memory in a non-contiguous manner. Nodes are connected by storing the address of the next node. We are given a linked list that will contain some integers in a random manner and not in a sorted manner. The task is to find the elements of the linked list which are repeated and we have to remove the duplicated ones. We will see the proper code and explanation. In this problem, we will keep the first copy of the elements of the ... Read More
Linked list is linear data structure and we have given a sorted linked list that consists of the integers. There are some numbers that may be duplicated or repeated and we have to remove them. As the given linked list is sorted, we can simply iterate over it and by using the while loop can remove the duplicate nodes from it. We will implement a proper code to understand the logic better with the discussion of time and space complexity. Example Given linked list is: 1-> 2 -> 2 -> 3 -> 4 -> 4 -> 4 -> 5 -> ... Read More
Golang has a built-in math package that provides various mathematical functions. In this article, we will focus on finding the inverse hyperbolic cosine of a complex number using the math/cmplx package in Golang. Inverse Hyperbolic Cosine Function The inverse hyperbolic cosine function (acosh) is the inverse function of the hyperbolic cosine function (cosh). It is defined for real numbers x ≥ 1, and its range is the set of non-negative real numbers. For complex numbers, acosh is defined as − acosh(z) = ln(z + sqrt(z^2 - 1)) where ln is the natural logarithm, sqrt is the square root, and ... Read More