Notes, summaries, assignments, exams, and problems for Computers

Sort by
Subject
Level

Constants pi type p decimals 2 value '3.1'

Classified in Computers

Written on in English with a size of 4.81 KB

Module 3 Quiz

1.Structured Query Language (SQL) is considered a procedural language. False
2.PL/SQL fully supports SQL data types. True
3. The term anonymous blocks refers to blocks of code that are not stored for reuse and do not exist after being executed. True
4.The BEGIN section of a PL/SQL block contains code that creates variables, cursors, and types. True
5. Assignment statements are used to put or change the values of variables. True
6. A disadvantage of using the %TYPE attribute is that there is a slight performance hit in that the database server must look up the data type from the data dictionary. True
7. A collection is a data type that can store multiple values of different data types as one unit. False
8. A scalar variable can hold multiple... Continue reading "Constants pi type p decimals 2 value '3.1'" »

Photography Processes and Techniques

Classified in Computers

Written on in English with a size of 2.48 KB

  • Developers - Produces a visible image from the latent image (1.5 - 2 min)
  • Stop - Terminates the development and removes excess of chemical (15 - 30 sec)
  • Fix - Removes the underdeveloped silver halide crystals from the emulsion (30 sec - 1 min)
  • Washed - Water, the final process (10 min)

Pinhole Photography - A pinhole camera is a simple camera without a lens but with a tiny aperture, a pinhole – effectively a light-proof box with a small hole in one side. Light from a scene passes through the aperture and projects an inverted image on the opposite side of the box, which is known as the camera obscura effect.

  • Sunny: 15-20 sec
  • Overcast: 60 sec
  • Cloudy: 2 min
  • Indoors: 30 min – 1 hour
  • Night Time: A few hours approx.

Photoshop Process:

  • Image Rotation: Image

... Continue reading "Photography Processes and Techniques" »

Understanding Binary Search Trees, Red-Black Trees, AVL Trees, Hash Tables, and HashMaps

Classified in Computers

Written on in English with a size of 40.07 KB

Binary Search Tree (BST)

Binary search tree (BST) is a tree in which all nodes follow the below mentioned properties:

  1. The left sub-tree of a node has a key less than or equal to its parent node's key.
  2. The right sub-tree of a node has a key greater than or equal to its parent node's key.
  3. Binary search tree (BST) divides all its sub-trees into two segments: left sub-tree and right sub-tree and can be defined as left_subtree (keys) ≤ node (key) ≤ right_subtree (keys).

Red-Black Tree

A red-black tree is a binary search tree in which each node is colored red or black. The root is black. The children of a red node are black. Every path from the root to leaf has the same number of black nodes and all leaves are black.

AVL Tree

Adelson, Velski & Landis

... Continue reading "Understanding Binary Search Trees, Red-Black Trees, AVL Trees, Hash Tables, and HashMaps" »

Understanding Network Characteristics and Protocols

Classified in Computers

Written on in English with a size of 5.89 KB

1. The performance of a client-server system is strongly influenced by two major network characteristics: the bandwidth of the network (that is, how many bits/sec it can transport) and the latency (that is, how many seconds it takes for the first bit to get from the client to the server). Give an example of a network that exhibits i) high bandwidth but also high latency, and ii) then give an example of one that has both low bandwidth and low latency. i) High bandwidth but also high latency: A transcontinental fiber link might have many gigabits/sec of bandwidth, but the latency will also be high due to the speed of light propagation over thousands of kilometers. Similarly, a satellite link may run at megabits/sec but have a high latency to... Continue reading "Understanding Network Characteristics and Protocols" »

Evolution of the iPhone: Early Models & Capabilities

Classified in Computers

Written on in English with a size of 1.68 KB

Evolution of the iPhone

Released on June 29, 2007, the iPhone has seen multiple new hardware iterations with new iOS releases since.

User Interface and Connectivity

The user interface is built around the device's multi-touch screen, including a virtual keyboard. The iPhone has Wi-Fi and can connect to cellular networks.

Core iPhone Features

An iPhone can:

  • Shoot video (standard feature from the iPhone 3GS)
  • Take photos
  • Play music
  • Send and receive email
  • Browse the web
  • Send and receive text messages
  • Follow GPS navigation
  • Record notes
  • Perform mathematical calculations
  • Receive visual voicemail

Other functionality, such as video games, reference works, and social networking, can be enabled by downloading mobile apps.

The App Store Ecosystem

As of January 2017, Apple'... Continue reading "Evolution of the iPhone: Early Models & Capabilities" »

Java HashSet1 Implementation Using HashTable

Classified in Computers

Written on in English with a size of 3.43 KB


public Class HashSet1

    implements IHashSet1

{   private IHashTable hashTable;

    private static final Object PRESENT = new Object();

    public HashSet1() {hashTable = new HashTable1();}

    public boolean add(Object o) {

        return hashTable.Put(o, PRESENT)==null;}

    public void clear() {hashTable.Clear();}

    public boolean contains(Object o) {

        return hashTable.ContainsKey(o);

}    public boolean containsAll(IHashSet1 s) {

        Iterator e = s.iterator();

        while(e.HasNext()) {

            if(!Contains(e.Next())) {

                return false;

            }

        }

        return true;

    }

    public boolean equals(Object... Continue reading "Java HashSet1 Implementation Using HashTable" »

Sequential Systems and Computer Memory Essentials

Classified in Computers

Written on in English with a size of 2.56 KB

Sequential Systems Design

A systematic way of designing any machine that passes through different states. Examples include counters, traffic lights, and vending machines. Generally called Finite State Machines/Automatas.

Mealy Machine

Outputs are a function of both inputs and the current state.

Moore Machine

Outputs are a function of the current state only.

Computer Memory

Part of the computer that stores information: instructions and data.

Organization:

Address: Identifies memory position

Content: Stored information

Memory Cell

Minimum storing element: one bit.

Word

Group of bits implied in each memory operation (8, 16, 32, 64, ... bits). It defines data bus size.

Basic Operations

Read (R) and Write (W)

Capacity

Maximum quantity of information that a memory

... Continue reading "Sequential Systems and Computer Memory Essentials" »

Graph Data Structures: Connectedness, Density, and Trees

Classified in Computers

Written on in English with a size of 41.84 KB

Connected and Disconnected Graphs

A graph is connected if any two vertices of the graph are connected by a path. Conversely, a graph is disconnected if at least two vertices are not connected by a path.

If a graph G is disconnected, then every maximal connected subgraph of G is called a connected component of graph G.

Dense and Sparse Graphs

A dense graph is a graph in which the number of edges is close to the maximal possible number of edges. Description: Connected graph Description:  Unconnected graph

A sparse graph is a graph in which the number of edges is close to the minimal possible number of edges. A sparse graph can be a disconnected graph.

Key Characteristics and Comparison

  • Informally, a graph with relatively few edges is sparse, and a graph with many edges is dense.
  • Sparse graphs are sparsely connected
... Continue reading "Graph Data Structures: Connectedness, Density, and Trees" »

TCP vs UDP: Key Differences & Protocol Characteristics

Classified in Computers

Written on in English with a size of 3.24 KB

Here's a breakdown of key characteristics and differences between TCP and UDP protocols:

  • TCP and UDP sockets are created by the transport layer: False
  • Before any data exchange takes place between two UDP applications, a logical connection must be established between them: False
  • Both SMTP and POP3 are TCP based: True
  • The UDP segment contains a checksum: True
  • The TCP segment contains a checksum: True
  • UDP makes use of the Selective Repeat protocol: False
  • The Selective Repeat algorithm is used for congestion control: False
  • HTTP uses TCP as its underlying transport protocol: True
  • With POP3, the email message is always deleted from the mail server if the client downloads the email message to its local email client application: False
  • Only TCP uses port numbers,
... Continue reading "TCP vs UDP: Key Differences & Protocol Characteristics" »

Shell Scripting Basics

Classified in Computers

Written on in English with a size of 2.58 KB

#!/bin/bash (Header .Sh)
echo
"text" ("print()")
chmod u+x file.Sh
g++ add.Cpp -o name (compile)
./add < input.Txt > output.Txt
pet="dog" (variable)
echo "Hello $var" (access var)
read var (input())
echo "$x" ("" echo var echo '$x')
echo "\$x" (echo special char)
a="`cat fl.Txt`" (stores shell cmd output)
echo ${#var} (No. Char in var)
echo ${a:6:3} (return substring ${a:pos:len})
echo ${a/$from/$to} (replace 'from' to 'to)
let "b = $a + 9" (does math and ans strd in var)
var="$0" ("$0" cmd line arg, "$@", @:all)


if [ condition ] | [ "$string" ] True; length of $string is non-0 | [ -e $file ] True iff file exists
then | [ "$string1" == "$string2" ] True; strings are equal | [ -f $file ] True iff file is a file
some action | [ "$string1" != "$string2"

... Continue reading "Shell Scripting Basics" »