Ankith Reddy has Published 1132 Articles

Computer languages

Ankith Reddy

Ankith Reddy

Updated on 27-Jun-2020 11:04:32

2K+ Views

There are mainly three different languages with the help of which we can develop computer programs. And they areMachine Level languageAssembly Level Language andHigh-Level LanguageMachine Level LanguageThe computer can understand only the language of Digital Electronics. Digital Electronics deals with the presence and absence of voltages. Within the computer there ... Read More

How to check android mobile supports ACCELEROMETER sensor?

Ankith Reddy

Ankith Reddy

Updated on 27-Jun-2020 10:44:57

428 Views

This example demonstrates How to check android mobile supports ACCELEROMETER sensorStep 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.Step 2 − Add the following code to res/layout/activity_main.xml. In the above code, ... Read More

die() function in PHP

Ankith Reddy

Ankith Reddy

Updated on 27-Jun-2020 08:57:19

3K+ Views

The die() function prints a message and exits the current script.Syntaxdie(msg)Parametersmsg − The message to write before exiting the script.ReturnThe die() function returns nothing.Example

FILTER_CALLBACK constant in PHP

Ankith Reddy

Ankith Reddy

Updated on 27-Jun-2020 08:51:17

68 Views

The FILTER_CALLBACK constant calls a user defined function to filter the value.ReturnThe FILTER_CALLBACK constant does not return anything.ExampleThe following is an example that converts the case of a string. Here, existing function in PHP is taken. Live DemoOutputThe following is the output.demo text!

FILTER_SANITIZE_NUMBER_FLOAT constant in PHP

Ankith Reddy

Ankith Reddy

Updated on 27-Jun-2020 08:48:16

303 Views

The FILTER_SANITIZE_NUMBER_FLOAT constant deletes all illegal characters from a float number.FlagsFILTER_FLAG_ALLOW_FRACTION − Allows fraction separatorFILTER_FLAG_ALLOW_THOUSAND − Allows thousand separatorFILTER_FLAG_ALLOW_SCIENTIFIC − Allows scientific notationReturnThe FILTER_SANITIZE_NUMBER_FLOAT constant does not return anything.ExampleThe following is an example that use FILTER_FLAG_ALLOW_FRACTION flag. Live DemoOutputThe following is the output.string(8) "3-1+2.56"Let us see another example. Here, FILTER_FLAG_ALLOW_THOUSAND flag ... Read More

FILTER_SANITIZE_SPECIAL_CHARS constant in PHP

Ankith Reddy

Ankith Reddy

Updated on 27-Jun-2020 08:43:48

493 Views

The FILTER_SANITIZE_SPECIAL_CHARS constant filter HTML-escapes special characters.FlagsFILTER_FLAG_STRIP_LOW − Strip characters with ASCII value below 32FILTER_FLAG_STRIP_HIGH − Strip characters with ASCII value above 32FILTER_FLAG_ENCODE_HIGH − Encode characters with ASCII value above 32ReturnThe FILTER_SANITIZE_SPECIAL_CHARS constant does not anything.Example Live DemoOutputThe following is the output.string(43) "Favorite Sports is Football & Cricket?"Read More

FILTER_VALIDATE_URL constant in PHP

Ankith Reddy

Ankith Reddy

Updated on 27-Jun-2020 08:24:36

209 Views

The FILTER_VALIDATE_URL constant validates a URL.FlagsFILTER_FLAG_SCHEME_REQUIRED − URL must be RFC compliant.FILTER_FLAG_HOST_REQUIRED − URL must include host name.FILTER_FLAG_PATH_REQUIRED −URL must have a path after the domain name.FILTER_FLAG_QUERY_REQUIRED −URL must have a query string.ReturnThe FILTER_VALIDATE_URL constant does not return anything.Example Live DemoOutputThe following is the output.Valid URL!Let us see another example.Example Live DemoOutputHere ... Read More

Microcomputer Basics

Ankith Reddy

Ankith Reddy

Updated on 27-Jun-2020 08:08:39

1K+ Views

A microcomputer can be defined as a small sized, inexpensive, and limited capability computer. It has the same architectural block structure that is present in a computer. Present-day microcomputers are having smaller sizes. Nowadays, they are of the size of a notebook. But in coming days also their sizes will ... Read More

RAM Addressing of 8051 Microcontroller

Ankith Reddy

Ankith Reddy

Updated on 27-Jun-2020 07:55:45

5K+ Views

Here we will see how external RAM memories can be addressed by the Intel 8051 microcontroller. There are different methods for addressing the RAMs. Now at first we will discuss about some different types of RAM memories in short.The RAM (Random Access Memory) is volatile memory. So when the power ... Read More

length() vs char_length() in MySQL?

Ankith Reddy

Ankith Reddy

Updated on 27-Jun-2020 07:39:24

715 Views

The char_length() can be used to display the length of a string. Let us see an example to get the length of the string included as a parameter.mysql> select char_length('John');The following is the output.+---------------------+ | char_length('John') | +---------------------+ | 4 ... Read More

Advertisements