Wednesday, August 28, 2019

Demonstration of fadeIn Method of jQuery

Demonstration of fadeIn Method of jQuery

ANIMATION

Code

<!DOCTYPE html>
<html>
<head>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.4.1/jquery.min.js"></script>
<script>
$(document).ready(function(){
  $("button").mouseenter(function(){
    $("#div1").fadeIn();
    $("#div2").fadeIn("slow");
    $("#div3").fadeIn(1000);
    $("#div4").fadeIn(2000);
    $("#div5").fadeIn(3000);
  });
 
  $("button").mouseleave(function(){
    $("#div1").fadeOut();
    $("#div2").fadeOut("slow");
    $("#div3").fadeOut(1000);
    $("#div4").fadeIn(2000);

    $("#div5").fadeIn(3000);
  });

});
</script>
<style>
body{
margin: 50px;
}
#button1{
  background-color: #f44336;;
  border: none;
  color: white;
  padding: 15px 32px;
  text-align: center;
  text-decoration: none;
  display: inline-block;
  font-size: 16px;
  margin: 4px 2px;
  cursor: pointer;
}

</style>
</head>
<body>

<h1>Demonstrate fadeIn() with different parameters.</h1>

<button id="button1">Hover the mouse to fade in boxes (move mouse over me and then move out )</button><br><br>


<div id="div1" style="width:90px;height:90px;display:none;background-color:#DD4132;">
</div><br>
<div id="div2" style="width:90px;height:90px;display:none;background-color:#79C753;">
</div><br>
<div id="div3" style="width:90px;height:90px;display:none;background-color:#FA9A85;">
</div><br>
<div id="div4" style="width:90px;height:90px;display:none;background-color:#F96714;">
</div><br>
<div id="div5" style="width:90px;height:90px;display:none;background-color:#FAE03C;">
</div>


</body>
</html>


Monday, August 26, 2019

Car2GO

                       Car2Go Website

Comment if you need code

Friday, August 23, 2019

Create a Digital Clock using HTML and JavaScript

Create a Digital Clock using HTML and JavaScript 




<!DOCTYPE html>
<html>
<head>

<script>
function startTime() {
  var today = new Date();
  var h = today.getHours();
  var m = today.getMinutes();
  var s = today.getSeconds();
  m = checkTime(m);
  s = checkTime(s);
  document.getElementById('txt').innerHTML =
  h + ":" + m + ":" + s;
  var t = setTimeout(startTime, 500);
}
function checkTime(i) {
  if (i < 10) {i = "0" + i};  // add zero in front of numbers < 10
  return i;
}
</script>

<style>
#txt{
color:white;
background-color:rgb(60, 60, 60);
padding:20px;
text-align: center;
margin: 60px;

}
</style>
</head>

<body onload="startTime()">

<div id="txt">  </div>

</body>
</html>



 



Thursday, August 22, 2019

Database Management Questions (MCQ) with Answers


     Database Management Questions (MCQ) with Answers


Q1 A relational database consists of a collection of

a)   Tables
b)   Fields                                                                                        
c)   Records
d)   Keys


Answer: a

Explanation: Fields are the column of the relation or tables. Records are each row in a relation. Keys are the constraints in a relation.


Q2 The term _______ is used to refer to a row. a) Attribute
b)   Tuple
c)   Field
d)   Instance


Answer: b
Explanation: Tuple is one entry of the relation with several attributes which are fields.

Q3  Course(course_id,sec_id,semester)
Here the course_id,sec_id and semester are __________ and course is a _________

a)   Relations, Attribute
b)   Attributes, Relation
c)   Tuple, Relation
d)   Tuple, Attributes



Answer: b
Explanation: The relation course has a set of attributes course_id,sec_id,  semester.

Q4) Which one of the following is used to define the structure of the relation, deleting relations and relating schemas?

a)   DML(Data Manipulation Langauge)
b)   DDL(Data Definition Langauge)
c)   Query
d)   Relational Schema



Answer: b
Explanation: Data Definition language is the language which performs all the operation in defining the structure of relation.

Q5 ) The basic data type char(n) is a _____ length character string and varchar(n) is _____ length character.

a)   Fixed, equal
b)   Equal, variable
c)   Fixed, variable
d)   Variable, equal



Answer: c
Explanation: Varchar changes its length accordingly whereas char has a specific length which has to be filled by either letters or spaces.


Q6) To remove a relation from an SQL database, we use the ______ command. a) Delete
b)   Purge
c)   Remove
d)   Drop table


Answer: d

Explanation: Drop table deletes the whole structure of the relation .purge removes the table which cannot be obtained again.

§ Q7)  PRIMARY KEY - Uniquely identifies each record in a table.
            a) True   b)false


Answer: a)

Q 8) Here which of the following displays the unique values of the column?

SELECT ________ dept_name     FROM instructor;

a)All
b)   From
c)   Distinct
d)   Name


Answer: c
Explanation: Distinct keyword selects only the entries that are unique.

Q 9 This Query can be replaced by which one of the following?
   SELECT name, course_id
   FROM instructor, teaches
   WHERE instructor_ID= teaches_ID;
a)   Select name,course_id from teaches,instructor where instructor_id=course_id;
b)   Select name, course_id from instructor natural join teaches;
c)   Select name, course_id from instructor;
d)   Select course_id from instructor join teaches;



Answer: b
Explanation: Join clause joins two tables by matching the common column.

Q10 In the given query which of the keyword has to be inserted?
INSERT INTO employee _____ (1002,Joey,2000);

a)   Table
b)   Values
c)   Relation
d)   Field



Answer: b
Explanation: Value keyword has to be used to insert the values into the table.

Q11)
SELECT * FROM employee WHERE dept_name="Comp Sci";
In the SQL given above there is an error . Identify the error.

a)   Dept_name
b)   Employee
c)   “Comp Sci”
d)   From




Answer: c
Explanation: For any string operations single-quoted(‘) must be used to enclose.


Q12 
SELECT emp_name  department
 dept_name LIKE ’ _____ceit’;
FROM WHERE
Which one of the following has to be added into the blank to select the dept_name which

has ceit as its ending string? 



a) %
b)   _
c)   ||
d)   $




Answer: a
Explanation: The % character matches any substring.

Q13)
SELECT name
FROM instructor
WHERE dept name = ’Physics’
ORDER BY name;

By default, the order by clause lists items in ______ order. 



a) Descending
b)   Any
c)   Same
d)   Ascending




Answer: d
Explanation: Specification of descending order is essential but it not for ascending.


Q14) In SQL the spaces at the end of the string are removed by _______ function.

a)   Upper
b)   String
c)   Trim
d)   Lower

Answer: c)

Q15)  _____ operator is used for appending two strings.


a) &
b)   %
c)   ||
d)   _


Answer: c
Explanation: || is the concatenation operator.


Q16) A Delete command operates on ______ relation. 

a) One
b)   Two
c)   Several
d)   Null


Answer: a
Explanation: Delete can delete from only one table at a time.

Q17) What type of join is needed when you wish to include rows that do not have matching values? 

a) Equi-join
b)   Natural join
c)   Outer join
d)   All of the mentioned


Answer: c
Explanation: An outer join does not require each record in the two joined tables to have a matching record..

Q18 PL/SQL programs are written as lines of text using a specific set of characters.


a.   Upper- and lower-case letters A .. Z and a .. z
b.  Numerals 0 .. 9
c.   Symbols ( ) + - * / < > = ! ~ ^ ; : . ' @ % , " # $ & _ | { } ? [ ]
d.  Tabs, spaces, and carriage returns
e.   All mentioned above




ANSWER: All mentioned above Explanation:
 
PL/SQL is not a case-sensitive language. The character set has some specific set of characters which are used for the writing PL/SQL programs.


Q19) ACID stands for:

a)     Atomicity, Consistency, Isolation, Durability
b)    Atomicity, Consistency, Isolated, Durable
c)     Atomicity, Concept, Isolation, Durability
d)    None of these

Answer: a)



Q20 Which of the following has a return type in its specification and must return a value specified in that type?
a.   Function
b.   Procedure
c.   Package
d.   None of the above.




ANSWER: Function 

Explanation: 

Functions in a subprogram act like new expressions and operators. A function computes a value in a subprogram. The function has a return clause.

Wednesday, August 7, 2019

Virtual Machine

Virtual Machine

Virtual Machine by Dinesh Kumar 

In computing, a virtual machine (VM) is an emulation of a computer system. Virtual machines are based on computer architectures and provide the functionality of a physical computer. Their implementations may involve specialized hardware, software, or a combination.


Wednesday, July 17, 2019

Fundamentals of Computers

Fundamentals of Computers


Computer is not an acronym, it is a word derived from a word "compute" which means to calculate. So, in simple words you can say that computer is an electronic device which is used for fast calculation.

Some people say that COMPUTER stands for Common Operating Machine Purposely Used for Technological and Educational Research. It is only a myth because first this definition does not make any sense and second when the computer were invented they were just calculating machines which needs a lot of space for establishment.



Aptitude-Problems on Ages

Aptitude Problems on Ages


Aptitude is a very important aspect of a person’s life. By aptitude, we usually understand Quantitative aptitude that basically judges our analytical and problem-solving skills. Aptitude is one of the most important parts of competitive exams and job interviews. You will find Aptitude questions in almost every exam paper. The reason is to judge the problem solving and decision-making skills of the candidate


Create a Digital Clock using HTML and JavaScript

Create a Digital Clock using HTML and JavaScript  <! DOCTYPE html> < html > < head > ...

Followers

Search This Blog

Popular Posts