Arjun Thakur has Published 1247 Articles

Role of CSS :only-child Selector

Arjun Thakur

Arjun Thakur

Updated on 01-Jul-2020 08:59:40

Use the CSS :only-child selector to style every element that is the only child of its parent.ExampleYou can try to run the following code to implement the :only-child selectorLive Demo                    p:only-child {             ... Read More

Generation of .HEX file using a linker

Arjun Thakur

Arjun Thakur

Updated on 30-Jun-2020 13:39:31

The file MULT.ASM which is created by using an editor is simply a text file. We cannot execute this file directly. At first we have to assemble the file, and then we have to link it. The step of assembly the translation of the program of assembly language to machine ... Read More

MySQL: What is 'AUTO_INCREMENT=5' in a create table query?

Arjun Thakur

Arjun Thakur

Updated on 30-Jun-2020 13:13:09

The AUTO_INCREMENT=5 in a create table query tells that the first record will start from 5 i.e. not default 1. As we know if you do not set the value to AUTO_INCREMENT then MySQL starts from 1 by default.The syntax is as follows:CREATE TABLE yourTableName ( yourColumnName1 dataType NOT NULL ... Read More

How do you append a carriage return to a value in MySQL?

Arjun Thakur

Arjun Thakur

Updated on 30-Jun-2020 12:30:09

You need to use CONCAT_WS() function from MySQL to append a carriage return. If you are looking for a new line, then append in the beginning. The syntax is as follows −SELECT CONCAT_WS(‘’, yourColumnName) as anyVariableName from yourTableName;To understand the above syntax, let us create a table. The query ... Read More

gmp_divexact() function in PHP

Arjun Thakur

Arjun Thakur

Updated on 30-Jun-2020 11:38:48

The gmp_divexact() function checks whether a GMP number is exactly divisible by another GMP number or not.Syntaxgmp_divexact($n, $divisor)Parametersn − The numberdivisor − The divisor valueReturnThe gmp_divexact() function returns the result of division.ExampleThe following is an example −OutputThe following is the output −4

gmp_div_q() function in PHP

Arjun Thakur

Arjun Thakur

Updated on 30-Jun-2020 11:34:20

The gmp_div_q() function performs division of GMP numbersSyntaxgmp_div_q(n1, n2)Parametersn1 − The first GMP number. It can be GMP object in PHP version 5.6 and later. Can also be numeric strings.n2 − The second GMP number. It can be GMP object in PHP version 5.6 and later. Can also be numeric ... Read More

gmp_com() function in PHP

Arjun Thakur

Arjun Thakur

Updated on 30-Jun-2020 11:31:56

The gmp_com() function computes the one’s complement of a GMP number.Syntaxgmp_com($val)Parametersval − The GMP number. It can be GMP object in PHP version 5.6 and later. Can also be numeric strings.ReturnThe gmp_com() function returns the one’s complement of a GMP number. The output is itself a GMP number.ExampleThe following is ... Read More

Style every element that is the second child of its parent with CSS

Arjun Thakur

Arjun Thakur

Updated on 30-Jun-2020 11:22:25

To style every element that is the second child of its parent with CSS, use the CSS :nth-child(n) selector.ExampleYou can try to run the following code to implement the :nth-child(n) selectorLive Demo                    p:nth-child(4) {         ... Read More

Conversion of Gray Code to Binary

Arjun Thakur

Arjun Thakur

Updated on 30-Jun-2020 11:15:22

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

Role of CSS :invalid Selector

Arjun Thakur

Arjun Thakur

Updated on 30-Jun-2020 11:12:44

Use the CSS :invalid selector to style all elements with an invalid value. You can try to run the following code to implement the :invalid selectorExampleLive Demo                    input:invalid {             background: red;          }                     Heading                    The style (red color background) appears if you type an irrelevant/ invalid email address.    

Advertisements