CSS Position Static

George John
Updated on 22-Jun-2020 07:34:21

269 Views

The position: static; property sets the position of an element static, which is the default.ExampleThe top, bottom, left, and right properties does not affect the the static positioned elements. You can try to run the following code to implement the CSS position: static; propertyLive Demo                    div.static {             position: static;             border: 3px solid blue;          }                     Positioning Element                       div element with position: static;               Output

Increment and Decrement Operators in C#

Samual Sam
Updated on 22-Jun-2020 07:34:05

7K+ Views

Increment operator increases integer value by one i.e.int a = 10; a++; ++a;Decrement operator decreases integer value by one i.e.int a = 20; a--; --a;The following is an example demonstrating increment operator −Example Live Demousing System; class Program {    static void Main() {       int a, b;       a = 10;       Console.WriteLine(++a);       Console.WriteLine(a++);       b = a;       Console.WriteLine(a);       Console.WriteLine(b);    } }Output11 11 12 12The following is an example demonstrating decrement operator −int a, b; a = 10; // displaying decrement operator result Console.WriteLine(--a); Console.WriteLine(a--); b = a; Console.WriteLine(a); Console.WriteLine(b);

Difference Between Break and Continue Statements in C#

George John
Updated on 22-Jun-2020 07:33:25

2K+ Views

The break statement terminates the loop and transfers execution to the statement immediately following the loop.The continue statement causes the loop to skip the remainder of its body and immediately retest its condition prior to reiterating.When the break statement is encountered inside a loop, the loop is immediately terminated and program control resumes at the next statement following the loop.The continue statement in C# works somewhat like the break statement. Instead of forcing termination, however, continue forces the next iteration of the loop to take place, skipping any code in between.The following is the complete code to use continue statement in a ... Read More

Advantage of CONCAT_WS Over CONCAT in SQL

Paul Richard
Updated on 22-Jun-2020 07:31:18

161 Views

As we know that CONCAT() function returns NULL if any of the arguments is NULL but CONCAT_WS() function returns NULL only if the first argument i.e. the separator is NULL and it ignores any other NULL. We can say this is the advantage of CONCAT_WS() function over CONCAT() function when we want to concatenate the values from the column and any of the columns have NULL as its value. To understand it, we consider the example from the table ‘Student_name; which have the following data −mysql> Select * from Student_Name; +---------+-------+---------+ | FName   | Mname | Lname   | ... Read More

Generate the First 100 Odd Numbers Using Chash

Chandu yadav
Updated on 22-Jun-2020 07:31:12

873 Views

To generate first 100 odd numbers, set a for loop from 1 to 100.for(val = 1; val

Declare NOT FOUND Handler in MySQL Cursor

varun
Updated on 22-Jun-2020 07:30:18

2K+ Views

We must have to declare NOT FOUND handler while working with MySQL cursor because it handles the situation when cursor could not find any row. It also handles the situation when the cursor reaches the end of the row because every time we call FETCH statement the cursor finds to attempt the next row in the result set. Following is the syntax to declare NOT FOUND handler −DECLARE CONTINUE HANDLER FOR NOT FOUND SET var_name = value;Here var_name is the name of any variable and value would be the value of that variable. For example, we can declare it as ... Read More

Retrieve Output with Decimal Values in Specified Format

Arjun Thakur
Updated on 22-Jun-2020 07:29:37

568 Views

MySQL FORMAT() function, converts a number to a format like #, ###, ###.### which is rounded up to the number of decimal places specified and returns the result as a string, can be used to retrieve the output having decimal values of a column in a specified format. To understand it, we are taking an example of table ‘estimated_cost’ which have the following data −mysql> Select * from estimated_cost; +----+-----------------+-----------+---------------+ | Id | Name_Company    | Tender_id | Tender_value  | +----+-----------------+-----------+---------------+ | 1  | ABC Ltd.        | 110       | 256.3256879   | | 2 ... Read More

System.Console Class and Its Methods in C#

karthikeya Boyini
Updated on 22-Jun-2020 07:29:16

886 Views

The System.Console class in C# represents the standard input, output, and error streams for console applications.The following are some of the methods of the System.Console class −Refer: MSDN System Class methodsSr.NoMethod & Description1Beep()Plays the sound of a beep through the console speaker.2Beep(Int32, Int32)Plays the sound of a beep of a specified frequency and duration through the console speaker.3Clear()Clears the console buffer and corresponding console window of display information.4MoveBufferArea(Int32, Int32, Int32, Int32, Int32, Int32)Copies a specified source area of the screen buffer to a specified destination area.5MoveBufferArea(Int32, Int32, Int32, Int32, Int32, Int32, Char, ConsoleColor, ConsoleColor)Copies a specified source area of the ... Read More

Role of CSS nth-last-child(n) Selector

Giri Raju
Updated on 22-Jun-2020 07:29:12

247 Views

Use the CSS :nth-last-child(n) selector to style every element that is the child of its parent, counting from the last child.You can try to run the following code to implement the :nth-last-child(n) selector −ExampleLive Demo                    p:nth-last-child(4) {             background: blue;             color: white;          }                     This is demo text 1.       This is demo text 2.       This is demo text 3.       This is demo text 4.       This is demo text 5.       This is demo text 6.     Output

Difference Between Write and WriteLine Methods in C#

Samual Sam
Updated on 22-Jun-2020 07:28:54

6K+ Views

The difference between Write() and WriteLine() method is based on new line character.Write() method displays the output but do not provide a new line character.WriteLine() method displays the output and also provides a new line character it the end of the string, This would set a new line for the next output.Let us see an example to learn about the difference between Write() and WriteLine() method −Example Live Demousing System; class Program {    static void Main() {       Console.Write("One");       Console.Write("Two");       // this will set a new line for the next output ... Read More

Advertisements