
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
George John has Published 1081 Articles

George John
1K+ Views
Three numbers can be swapped in cyclic order by passing them to a function cyclicSwapping() using call by reference. This function swaps the numbers in a cyclic fashion.The program to swap numbers in cyclic order using call by reference is given as follows −Example Live Demo#include using namespace std; void cyclicSwapping(int ... Read More

George John
107 Views
Set a radial gradient as the background image, with radial-gradient() CSS function. You can try to run the following code to implement linear-gradient() function in CSSExampleLive Demo #demo { height: 200px; background: radial-gradient(green, orange, maroon); } Setting background as radial gradient.

George John
422 Views
The function getchar_unlocked() is deprecated in Windows because it is a thread unsafe version of getchar(). It is suggested not to use getchar_unlocked(). There is no stream lock check that’s why getchar_unlocked is unsafe. The function getchar_unlocked() is faster than getchar().Here is the syntax of getchar_unlocked() in C language, int ... Read More

George John
118 Views
Use the grid-template-rows property to set the number of rows in a grid layoutExampleLive Demo .container { display: grid; background-color: green; grid-template-rows: auto auto; padding: 20px; grid-gap: 20px; } .container > div { background-color: orange; border: 2px solid gray; padding: 35px; font-size: 30px; text-align: center; } .ele1 { grid-row-start: 1; grid-row-end: 6; } Game Board 1 2 3 4 5 6

George John
227 Views
We can achieve this with the help of SHOW command. Firstly, I will use my database with the help of USE command −mysql> USE business; Database changedWe are in the “business” database now. After that, we can check that how many tables are available for this database. The query is ... Read More

George John
6K+ Views
To understand whether a column exist or not, we have the following approaches −With the help of DESC commandUsing SHOW commandFirstly, we will create a table with columns −mysql> CREATE table ColumnExistDemo -> ( -> UniqueId int, -> UniqueName varchar(200), -> UniqueAddress varchar(200) -> ); Query OK, 0 rows affected ... Read More

George John
60 Views
Set where to end the grid-items with CSS grid-row-start property.You can try to run the following code to implement the grid-row-end propertyExampleLive Demo .container { display: grid; grid-auto-rows: 50px; grid-gap: 10px; background-color: red; padding: 10px; } .container>div { background-color: yellow; text-align: center; padding:10px 0; font-size: 20px; } .ele3 { grid-row-end: span 2; } 1 2 3 4 5 6

George John
424 Views
Yes, it is possible. Create a pattern using the image, and then set the pattern to fillStyle.Here, obj is our image object −var context = canvas.getContext("2d"); var pattern = context.createPattern(obj, "repeat"); context.fillStyle = pattern;You need to manipulate the image to fit an arbitrary polygon −context.save(); context.setTransform(m11, m12, m21, m22, dx, ... Read More

George John
979 Views
To remove leading and trailing space, we can use the trim() in MySQL. Firstly, we will create a table with the help of CREATE command.Creating a table −mysql> CREATE table TrailingANdLeadingDemo -> ( -> SpaceTrailLead varchar(100) -> ); Query OK, 0 rows affected (0.57 sec)After creating a table, we will ... Read More

George John
835 Views
To scale fonts, let us see an example.Canvas: 800px Font Size: 60pxYou need to use the following code for our example to scale font size based on canvas −var fontBase = 800; var fontSize = 60; function getFont() { var ratio = fontSize / fontBase; var cSize = canvas.width * ratio; return (cSize |0) + 'px sans-serif'; }