Notes, abstracts, papers, exams and problems of Computers

Sort by
Subject
Level

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

Classified in Computers

Written at on 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 at on 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" »

Java HashSet1 Implementation Using HashTable

Classified in Computers

Written at on 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 at on 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" »

TCP vs UDP: Key Differences & Protocol Characteristics

Classified in Computers

Written at on 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 at on 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" »

Understanding Computer Data Storage: Memory and Mass Storage

Classified in Computers

Written at on English with a size of 2.2 KB.

Computer Data Storage

Computer data storage, often called storage or memory, refers to computer components, devices, and recording media that retain digital data used for computing for some interval of time. Computer data storage provides one of the core functions of the modern computer: information retention. It is one of the fundamental components of all modern computers and, coupled with a central processing unit (CPU, a processor), implements the basic computer model used since the 1940s.

In contemporary usage, memory usually refers to a form of semiconductor storage known as random access memory (RAM) and sometimes other forms of fast but temporary storage. Similarly, storage today more commonly refers to mass storage: optical discs, forms... Continue reading "Understanding Computer Data Storage: Memory and Mass Storage" »

Internet Safety and Digital Responsibility Guide

Classified in Computers

Written at on English with a size of 5.88 KB.

What is the Internet?

The internet is a vast network of thousands of computers and devices worldwide, connected through various means like copper wires, fiber optics, and wireless connections.

Internet of Things

The Internet of Things (IoT) is a revolutionary concept that describes the connection of everyday objects to the internet. This interconnectedness allows us to interact with these objects remotely and seamlessly.

Web Browsers

A web browser is a software program that retrieves and displays the content of web pages. It acts as your gateway to accessing information and resources on the internet.

Search Engines

Search engines are sophisticated computer systems that index files stored on websites across the internet. They continuously crawl and... Continue reading "Internet Safety and Digital Responsibility Guide" »

Advantages and Disadvantages of Primary and Secondary Data Collection

Classified in Computers

Written at on English with a size of 2.99 KB.

Primary data:

  • Any data that is personally collected by you. Primary data may include traffic counts, pedestrian counts, environmental indexes, questionnaires or land use surveys.

Secondary data:

  • Any data that has been collected by someone else. Secondary data collection may be found in books, on the internet, in academic journals, etc.

Census:

  • A survey carried out by nearly all countries every 10 years. It is a very detailed survey that is compulsory for everyone to fill in.



Advantages of Primary Data:

  • It is up to date (current).
  • You know how the data has been collected.
  • Includes data relevant to coursework.
  • Only covers your study area.
  • Collected in the format that you want.

Advantages of Secondary Data:

  • Can study temporal changes.
  • It can be quicker, especially
... Continue reading "Advantages and Disadvantages of Primary and Secondary Data Collection" »

Troubleshooting Wireless Network Issues: A Comprehensive Guide

Classified in Computers

Written at on English with a size of 3.83 KB.

It permits traffic from wireless clients in 10.10.10 y 10.10.20The solution must have active PEFNG licensesHave Radius server send different roles for users in different departments.Apply role-based firewall policiesChange user to any in the user any svc-dhcp permit ruleClientMatchAirwave combines information from more sources, such as Radius authenticating servers and APsWireless security camera operating on channel 8To support more POE devices directly connected to the MCSet the VLANs associated with desired subnets in the WLAN settingsRADIUS serverAddition of custom rules to control access for authenticated guestsIt removes any commands that are not supported on that MC or have dependency errorsMesh Portal APChoose ClearPass or the other

... Continue reading "Troubleshooting Wireless Network Issues: A Comprehensive Guide" »