Let us first create a table −mysql> create table DemoTable -> ( -> Value int -> ); Query OK, 0 rows affected (1.33 sec)Insert some records in the table using insert command −mysql> insert into DemoTable values(25); Query OK, 1 row affected (0.11 sec) mysql> insert into DemoTable values(75); Query OK, 1 row affected (0.11 sec) mysql> insert into DemoTable values(100); Query OK, 1 row affected (0.13 sec)Display all records from the table using select statement −mysql> select * from DemoTable;This will produce the following output −+-------+ | Value | +-------+ | 25 | | ... Read More
The onseeked attribute executes a script when the user skips or moves to a new position in the audio or video.ExampleYou can try to run the following code to implement onseeked attribute − Play Your browser does not support the video element. function myFunction() { document.getElementById("test").innerHTML = "Current position: " + document.getElementById("myid").currentTime; }
Use the onsuspend attribute in HTML to run the script when the loading of media data suspends, for example, when download completes. It can happen in any of the following situations −When a download is paused When a download completes Media is suspended, etc.The attribute can be used with the and elements and works in all the modern web browsers such as Firefox, Chrome, Opera, Safari, etc.
When a user opens or closes the element, the ontoggle event fires. You can try to run the following code to implement ontoggle event attribute −Example Details You need to join office from Feb23 More Information Timings: 9 to 5:30 Office location: Hyderabad function myFunction() { alert("Timings, office location, etc"); }
Use the tag in HTML to specify citation. Cite can be defined as the title of a work. You can try to run the following code to implement tag for adding citation −Example HTML cite Tag The learning content can be referred from Data Structures & Algorithms in Java
Use the tag to insert a single line break in HTML. You can try to run the following code to insert a line break using the tag −Example HTML br Tag This is before the line break and this after the line break.
Use the dir tag in HTML to display directory list. This is very similar to tag but do not use since it is deprecated now.The following is the attribute −AttributeValueDescriptionCompactcompactDeprecated − Specifies a compact rendering.ExampleYou can try to run the following code to show a directory list in HTML − HTML dir Tag The following are the values: car bike ship
In this article we will see how to create a list of lists which contain string data types. The inner list themselves or of string data type and they may contain numeric or strings as their elements.Using strip and splitWe use these two methods which will first separate out the lists and then convert each element of the list to a string.Example Live Demolist1 = [ '[0, 1, 2, 3]', '["Mon", "Tue", "Wed", "Thu"]' ] print ("The given list is : " + str(list1)) print("") # using strip() + split() result = [k.strip("[]").split(", ") for k in list1] print ("Converting list ... Read More
The cmp() is part of the python standard library which compares two integers. The result of comparison is -1 if the first integer is smaller than second and 1 if the first integer is greater than the second. If both are equal the result of cmp() is zero.Below example illustrates different scenario showing the use of cmp() method.Example Live Demodef cmp(x, y): return (x > y) - (x < y) #x>y x = 5 y = 3 print("The cmp value for x>y is : ",cmp(x, y),"") #xy is : 1 The cmp value for x
Use the tag to define area in an image map in HTML.The HTML tag supports the following additional attributes −AttributeValueDescriptionAltTextSpecifies an alternate text for the area.coordsif shape = "rect" then coords = "left, top, right, bottom"if shape = "circ" then coords = "centerx, centery, radius"if shape = "poly" then coords = "x1, y1, x2, y2, .., xn, yn"Specifies the coordinates appropriate to the shape attribute to define a region of an image for image maps.download filenameSpecifies that the target gets downloaded when the hyperlink is clicked by the user.HrefURLSpecifies the URL of a page or the name of ... Read More
Data Structure
Networking
RDBMS
Operating System
Java
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP