Ankith Reddy has Published 1070 Articles

How to set the range that is considered to be of high value in HTML?

Ankith Reddy

Ankith Reddy

Updated on 03-Mar-2020 09:56:18

68 Views

Use the high attribute in HTML to set the range that is considered to be of high value in HTML.ExampleYou can try to run the following code to implement the high attribute −                    Water Level:                    

Execute a script when the user writes something in a search field in HTML?

Ankith Reddy

Ankith Reddy

Updated on 03-Mar-2020 09:37:13

131 Views

Use the onsearch attribute in HTML to execute a script when the user writes in a search field and press ENTER or x.ExampleYou can try to run the following code to implement the onsearch attribute −           Search something and press ENTER.       ... Read More

Execute a script as long as the mouse pointer is moving over an element in HTML?

Ankith Reddy

Ankith Reddy

Updated on 03-Mar-2020 07:29:12

90 Views

When the mouse pointer is moving over an element, the onmousemove attribute triggers. You can try to the following code to implement onmousemove attribute −Example                    This is demo heading.            Click above and then release.               function mouseMove() {         document.getElementById("myid").style.color = "red";         }          

How do we specify that the audio/video will start playing as soon as it is ready in HTML?

Ankith Reddy

Ankith Reddy

Updated on 02-Mar-2020 12:44:10

218 Views

Use the autoplay attribute to set that the audio or video will start playing automatically as the page loads.ExampleYou can try to run the following code to implement autoplay attribute in HTML −                                        Your browser does not support the video element.          

Why should C++ programmers minimize use of 'new'?

Ankith Reddy

Ankith Reddy

Updated on 02-Mar-2020 08:07:45

50 Views

new is used for dynamic memory allocation. The memory allocated in this case goes on the heap. There are several costs associated with this type of memory allocation along with the programmer having to do manual memory cleaning and management. This type of allocation must be used when − You don't ... Read More

What should be the order in which libraries are linked in GCC?

Ankith Reddy

Ankith Reddy

Updated on 02-Mar-2020 07:52:22

844 Views

The linker searches from left to right. While doing so it encounters unresolved symbols which it keeps track of. If a library resolves the unresolved symbol, it takes the object files of that library to resolve the symbol.Dependencies of static libraries from each other work in the same way. Libraries ... Read More

How MySQL virtual GENERATED COLUMNS can work with mathematical expressions?

Ankith Reddy

Ankith Reddy

Updated on 21-Feb-2020 11:39:55

103 Views

It can be illustrated with the help of an example in which we are creating a virtual generated column in the table named ‘triangle’. As we know that virtual generated column can be generated with or without using the keyword ‘virtual’.Examplemysql> Create table triangle(SideA DOUBLE, SideB DOUBLE, SideC DOUBLE AS ... Read More

How MySQL can perform case-sensitive string comparison?

Ankith Reddy

Ankith Reddy

Updated on 17-Feb-2020 06:01:43

494 Views

As we know that MySQL is not case-sensitive while comparing characters but it can be changed i.e. MySQL can perform case-sensitive string comparison if we will use BINARY keyword before the expression. Actually, BINARY keyword instructs MySQL to compare the characters in the string using their underlying ASCII values rather ... Read More

Sorting a vector of custom objects using C++ STL

Ankith Reddy

Ankith Reddy

Updated on 12-Feb-2020 06:19:23

12K+ Views

You can sort a vector of custom objects using the C++ STL function std::sort. The sort function has an overloaded form that takes as arguments first, last, comparator. The first and last are iterators to first and last elements of the container. The comparator is a predicate function that can ... Read More

How can I use SPACE() function with MySQL WHERE clause?

Ankith Reddy

Ankith Reddy

Updated on 10-Feb-2020 06:24:38

223 Views

In this case, SPACE() function would add white spaces depending upon the condition given in WHERE clause. The following example from student table will demonstrate it.Examplemysql> Select Id, Name, Space(5) from student WHERE Name='Harshit'; +------+---------+----------+ | Id   | Name    | Space(5) | +------+---------+----------+ | 15   | Harshit ... Read More

Advertisements