- Trending Categories
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
Physics
Chemistry
Biology
Mathematics
English
Economics
Psychology
Social Studies
Fashion Studies
Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Karthikeya Boyini has Published 2382 Articles
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
1K+ Views
If you have a numeric library like numpy available, you should use the reshape method to reshape the tuple to a multidimensional array. exampleimport numpy data = numpy.array(range(1, 10)) data.reshape([3, 3]) print(data)OutputThis will give the output −array([[1, 2, 3], [4, 5, 6], [7, 8, 9]])ExampleIf ... Read More
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
151 Views
You can use tuples to represent immutable vectors in Python. Tuples are immutable data structures that behave like a list but maintain order and are faster than lists. examplemyVec = (10, 15, 21) myVec[0] = 10This will produce an error as tuples can't be mutated.
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
4K+ Views
You can combine multiple print statements per line using, in Python 2 and use the end argument to print function in Python 3.examplePython2.x print "Hello", print " world" Python3.x print ("Hello", end='') print (" world")OutputThis will give the output −Hello worldAnother thing you could do is put all the ... Read More
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
1K+ Views
Use the :focus class to change the color of focused links. Possible values could be any color name in any valid format.ExampleYou can try to run the following code to implement the color of the focused link − a:focus { color: #0000FF } This is demo link
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
67 Views
Use the :first-child pseudo class to add special style to an element that is the first child of some other element.ExampleYou can try to run the following code to understand the usage of :first-child pseudo class − div > p:first-child ... Read More
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
185 Views
The z-index property is used along with the position property to create an effect of layers. You can specify which element should come on top and which element should come at the bottom. ExampleYou can try to run the following code to implement the z-index property −
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
91 Views
The visibility property with value visible is used to make an element visible. You can try to implement the following code to implement the visible property − Example p { visibility: hidden; } This paragraph is visible. This paragraph won't be visible.
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
53 Views
Use the CSS overflow property to solve this issue of a content exceeding the allocated space. You can try to run the following code to solve the issue −Example .scroll{ display:block; border: 2px ... Read More
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
120 Views
The line-height property is used to set the height of a line of text. The value of the line-height property can be a number, a length, or a percentage.Example This paragraph is 300 pixels wide and 100 pixels high and here line height is 50 pixels.