Introduction: In this article let’s learn how to implement gradient descent in python. Gradient descent is a method of minimizing the cost function by an iterative method. In this method, we assume initial weights(theta) and go on minimizing these weights by learning rate. Here learning rate defines how the weights have to be changed so […]

## RTOS Task switching based on priority using LCD – CodesExplorer

Prerequisites:- The prerequisite for this program you should have knowledge of Simple LCD interfacing on ARM LPC2148. You can visit this post to get the program, algorithm about LCD interfacing. Introduction:- In this post, We will be dealing with RTOS(Real-time Operating System) Program to switch the tasks based on the priorities.At first the OS is initialised […]

## RTOS program to generate Round Bin Multitasking algorithm

In this article let’s learn to assign tasks in round robin fashion.In the following program first it assigns highest priority to task1 and then it creates task2,task3. It continous the execution and waits for event in task1,then suspend task1 and then enters into task2. Next it waits for event in task2,then suspend task2 and then […]

## Classes and Objects

Classes and Objects Classes and Objects: Class is a user defined data type just like Structures, but with the difference. It also has 3 sections namely 1. private, 2. public and 3. protected. Using these, access to member variable of a class can be strictly controlled. public : variable and functions are accessible to any […]

## Inline function in c++

INLINE FUNCTION INLINE FUNCTION: The inline function is the concept used commonly with classes. When the function is inline, the compiler places a copy of the code of that function at each point. Conditions for the Inline function: Inline functions should not contain any loops, recursion. – The inline function is only applicable for […]

## Arm thumb program to find first 10 fibonacci numbers

In this article let’s learn how to find first 10 Fibonacci numbers.Usually Fibonacci numbers start from 0,1,1,2……In this, we can observe that the present number in Fibonacci is the summation of previous two numbers. So in this, we should initialize first two numbers as -1 and +1 so that our algorithm works fine. Let’s […]

## Java program to compute employee’s net salary,HRA,DA and GS

In this article let’s learn how to calculate the net salary of an employee by considering the parameters called HRA(House rent allowance),DA(Dearness allowance),GS (Gross salary)and income tax. Let us assume some parameters.HRA=10% of basic salaryDA=73% of basic salaryGS=basic salary+DA+HRAIncome tax=30% of gross salarynet salary= GS-income tax Algorithm:1)Start2)Take the input from the user as employee name,id […]

## ARM assembly code to find number of ones and zeros in a 32 bit number

Hello guys! Today we will see how to find number of ones and zeros in a 32 bit number. Let’s first understand the algorithm later we see a example code. Algorithm: Start Store a 32 bit number in register(Rd). Initialize a counter register to 1Fh(32) Initialize one regiter(Ra) to zero to store number of ones, […]

## 8051 code find sum of first N natural numbers

Hello, guys! Today we will see 8051 assembly program to find the sum of first N natural numbers. There are two ways to compute the sum of N natural numbers. We will go through one by one. First method: It’s simple basic code. Let’s go through the algorithm. Algorithm: Start Store the value(N) up to which sum […]

## 8051 program to convert Ascii value to Hexadecimal value….

Hi guys…In this article let’s learn conversion.The ascii to Hex conversion logic is very simple.The hexadecimal numbers from 31H-39H are 0-9 numbers in ascii and 41H to 46H are A to F numbers. So we should first compare the number with 40H if it is lesser subtract with 30H and it is greater subtract with […]