Ankith Reddy has Published 1070 Articles

Unsigned and Signed Binary Numbers

Ankith Reddy

Ankith Reddy

Updated on 01-Nov-2023 01:26:11

49K+ Views

Variables such as integers can be represent in two ways, i.e., signed and unsigned. Signed numbers use sign flag or can be distinguish between negative values and positive values. Whereas unsigned numbers stored only positive numbers but not negative numbers.Number representation techniques like: Binary, Octal, Decimal, and Hexadecimal number representation ... Read More

Timers of 8051

Ankith Reddy

Ankith Reddy

Updated on 31-Oct-2023 21:54:08

59K+ Views

In Intel 8051, there are two 16-bit timer registers. These registers are known as Timer0 andTimer1. The timer registers can be used in two modes. These modes areTimer mode and the Counter mode. The only difference between these two modes is the source for incrementing the timer registers. Timer ModeIn the ... Read More

Interfacing Stepper Motor with 8051Microcontroller

Ankith Reddy

Ankith Reddy

Updated on 31-Oct-2023 21:33:56

60K+ Views

In this section, we will see how to connect a stepper motor with Intel 8051 Microcontroller. Before discussing the interfacing techniques, we will see what are the stepper motors and how they work.Stepper MotorStepper motors are used to translate electrical pulses into mechanical movements. In some disk drives, dot matrix ... Read More

Conversion of Binary to Gray Code

Ankith Reddy

Ankith Reddy

Updated on 31-Oct-2023 13:38:45

74K+ Views

The reflected binary code or Gray code is an ordering of the binary numeral system such that two successive values differ in only one bit (binary digit). Gray codes are very useful in the normal sequence of binary numbers generated by the hardware that may cause an error or ambiguity ... Read More

How to check if a C/C++ string is an int?

Ankith Reddy

Ankith Reddy

Updated on 31-Oct-2023 03:32:51

24K+ Views

There are several methods to check that string is an int or not and one of those method is to use isdigit() to check the string.Here is an example to check whether a string is an int or not in C++ language, Example Live Demo#include #include using namespace std; int ... Read More

Substring in C++

Ankith Reddy

Ankith Reddy

Updated on 07-Oct-2023 01:44:35

23K+ Views

A substring is a part of a string. A function to obtain a substring in C++ is substr(). This function contains two parameters: pos and len. The pos parameter specifies the start position of the substring and len denotes the number of characters in a substring.A program that obtains the ... Read More

SELECT where row value contains string in MySQL?

Ankith Reddy

Ankith Reddy

Updated on 05-Oct-2023 01:06:33

30K+ Views

To select the row value containing string in MySQL, use the following syntax.SELECT *FROM yourTableName where yourColumnName like ‘%yourPattern%’;To understand the above syntax, let us first create a table. The query to create a table is as follows.mysql> create table PatternDemo -> ( -> Id int, -> Name varchar(100), -> ... Read More

Stack and the stack pointer in 8085 Microprocessor

Ankith Reddy

Ankith Reddy

Updated on 04-Oct-2023 20:45:39

28K+ Views

The stack is a LIFO (last in, first out) data structure implemented in the RAM area and is used to store addresses and data when the microprocessor branches to a subroutine. Then the return address used to get pushed on this stack. Also to swap values of two registers and ... Read More

Best way to test if a row exists in a MySQL table

Ankith Reddy

Ankith Reddy

Updated on 06-Sep-2023 21:41:54

41K+ Views

To test whether a row exists in a MySQL table or not, use exists condition. The exists condition can be used with subquery. It returns true when row exists in the table, otherwise false is returned. True is represented in the form of 1 and false is represented as 0.For ... Read More

C Program for LowerCase to UpperCase and vice-versa

Ankith Reddy

Ankith Reddy

Updated on 02-Sep-2023 13:20:59

61K+ Views

Here is the program to convert a string to uppercase in C language, Example Live Demo#include #include int main() {    char s[100];    int i;    printf("Enter a string : ");    gets(s);    for (i = 0; s[i]!='\0'; i++) {       if(s[i] >= ... Read More

Advertisements