Computer Fundamental & Problem Solving Techniques

UNIT-I: Introduction to Internet


  • Definition: The Internet is a global network of interconnected computers that communicate using standardized protocols.
  • How it works: Computers on the Internet exchange data using the TCP/IP protocol suite, which enables reliable, end-to-end communication.
  • Importance: The Internet has revolutionized communication, information sharing, and commerce, connecting billions of people worldwide.

Growth of Internet

  • History: The Internet originated from the ARPANET project, developed by the US Department of Defense in the 1960s to enable communication between research institutions.
  • Factors: The growth of the Internet has been driven by advancements in computer and networking technology, increasing accessibility through personal computers and mobile devices, and the ever-growing demand for information and services online.
  • Current status: As of 2024, over 4.5 billion people, or more than 59% of the world’s population, are Internet users.

Owners of the Internet

  • No single owner: The Internet is a decentralized network of networks, with no single entity controlling its entirety.
  • Key organizations: The Internet Corporation for Assigned Names and Numbers (ICANN) manages the allocation of domain names and IP addresses, while the Internet Engineering Task Force (IETF) develops and maintains the technical standards that enable Internet communication.
  • Challenges: The decentralized nature of the Internet presents challenges in balancing control, security, and openness, with various stakeholders having different interests and priorities.

Anatomy of Internet

  • Infrastructure: The physical components of the Internet include servers, routers, switches, and the cables and wireless links that connect them.
  • Protocols: Data transmission on the Internet is governed by a set of rules called protocols, with the most important being the Transmission Control Protocol/Internet Protocol (TCP/IP) suite.
  • ISPs: Internet Service Providers (ISPs) are companies that provide individuals and organizations with access to the Internet, acting as gateways between users and the global network.

ARPANET and Internet history

  • ARPANET: The Advanced Research Projects Agency Network (ARPANET) was a precursor to the Internet, developed by the US Department of Defense to enable communication between research institutions.
  • Milestones: Key milestones in the development of the Internet include the introduction of the TCP/IP protocol suite in 1983, the invention of the World Wide Web by Tim Berners-Lee in 1990, and the commercialization of the Internet in the mid-1990s.

World Wide Web

  • Definition: The World Wide Web (WWW) is a system of interlinked hypertext documents accessed via the Internet, enabling users to navigate between web pages using hyperlinks.
  • Invention: The World Wide Web was created by British computer scientist Tim Berners-Lee at CERN (European Organization for Nuclear Research) in 1989.
  • Growth: The Web grew rapidly in the 1990s and 2000s, with the development of user-friendly web browsers and the increasing availability of online content and services.

Basic Internet Terminology

  • URL: A Uniform Resource Locator (URL) is the address of a web page, specifying its location on the Internet.
  • Domain: A domain is a unique name that identifies a website, such as “,” and is used in URLs to specify the location of web pages.
  • Server: A server is a computer that hosts websites and provides services to clients, responding to requests for data and resources.

Net etiquette

  • Be respectful: Internet users should treat others online with courtesy and respect, avoiding harassment, hate speech, and personal attacks.
  • Protect privacy: Users should be cautious about sharing personal information online and respect the privacy of others.
  • Consequences: Violations of net etiquette can lead to consequences such as account suspensions, bans from online communities, or even legal action in severe cases.

Internet Applications

Commerce on the Internet

  • E-commerce: E-commerce refers to the buying and selling of goods and services over the Internet, encompassing activities such as online shopping, electronic payments, and online auctions.
  • Benefits: E-commerce offers advantages such as convenience, a wider choice of products and services, competitive prices, and the ability to shop from anywhere at any time.
  • Challenges: E-commerce also presents challenges, including security concerns (e.g., fraud, data breaches), logistical issues (e.g., shipping, returns), and the need for consumer protection.

Governance on the Internet

  • Role of governments: Governments play a role in regulating the Internet through laws, policies, and sometimes censorship, aiming to address issues such as cybercrime, intellectual property rights, and online privacy.
  • Freedom of speech: A key challenge in Internet governance is balancing the right to free expression with the need to protect public safety, security, and the rights of others.
  • International cooperation: As the Internet transcends national borders, international cooperation is essential to address cross-border issues like cybercrime, data protection, and the global digital divide.

Impact of Internet on Society

Crime on/through the Internet

  • Types of cybercrime: Cybercrime includes activities such as hacking (unauthorized access to computer systems), phishing (fraudulent attempts to obtain sensitive information), malware (malicious software), and online scams.
  • Impact: Cybercrime can result in financial losses for individuals and businesses, privacy breaches, reputational damage, and the erosion of trust in online systems.
  • Prevention: Strategies to prevent and combat cybercrime include using strong passwords, keeping software up to date, using security software (e.g., antivirus, firewalls), and promoting user awareness and education.

UNIT-II: Internet Connectivity & Network

1. Connectivity types

  • Level one connectivity: Basic access to the Internet, typically through dial-up or low-speed connections
  • Level two connectivity: Higher-speed access, such as DSL or cable modem connections, offering faster data transfer rates
  • Level three connectivity: High-speed, dedicated connections, such as leased lines or fiber optic connections, suitable for large organizations and enterprises

2. Modem

  • Definition: A device that modulates and demodulates signals to convert digital data from a computer into analog signals for transmission over telephone lines, and vice versa
  • Types: Dial-up modems, cable modems, DSL modems
  • Role: Enables computers to connect to the Internet through telephone lines or cable networks

3. Dedicated connections through the telephone system

  • Leased lines: Dedicated, point-to-point connections that provide a constant, high-speed link between two locations
  • T1/E1 lines: High-capacity, digital telephone lines that can carry voice and data traffic simultaneously
  • Fractional T1/E1: Portions of a T1/E1 line, allowing for customized bandwidth allocation

4. ISDN (Integrated Services Digital Network)

  • Definition: A set of communication standards for simultaneous digital transmission of voice, video, data, and other network services over the traditional circuits of the public switched telephone network
  • Types: Basic Rate Interface (BRI) and Primary Rate Interface (PRI)
  • Advantages: Faster than traditional dial-up connections, supports multiple devices, and provides a reliable, high-quality connection

5. Protocol options

  • Shell: A command-line interface for accessing remote computers and executing commands
  • SLIP (Serial Line Internet Protocol): A simple protocol for transmitting IP packets over a serial line, used for dial-up Internet access
  • PPP (Point-to-Point Protocol): A more advanced protocol that provides error detection, compression, and authentication, widely used for dial-up and broadband Internet connections

6. Service options

  • E-mail: Electronic mail service for sending and receiving messages over the Internet
  • WWW (World Wide Web): A system of interlinked hypertext documents accessed through the Internet
  • News: Online discussion forums and newsgroups where users can read and post messages on various topics
  • Firewall: A security system that monitors and controls incoming and outgoing network traffic based on predetermined security rules

7. Network definition

  • A network is a collection of computers, servers, and other devices that are connected to share resources, exchange files, and communicate with each other

8. Common terminologies

  • LAN (Local Area Network): A network that connects computers and devices within a limited area, such as a home, office, or building
  • WAN (Wide Area Network): A network that spans a large geographical area, connecting multiple LANs and other networks
  • Node: Any device connected to a network, such as a computer, printer, or server
  • Host: A computer connected to a network that provides services or resources to other computers
  • Workstation: A powerful computer, often used for specialized tasks such as graphic design or scientific simulations
  • Bandwidth: The maximum amount of data that can be transmitted over a network connection in a given amount of time, usually measured in bits per second (bps)
  • Interoperability: The ability of different systems, devices, or software to work together and exchange information seamlessly
  • Network administrator: A person responsible for managing, maintaining, and securing a network
  • Network security: The practice of protecting a network and its resources from unauthorized access, misuse, disruption, or modification

UNIT-III: Internet Security Management Concepts

1. Overview of Internet Security

  • Definition: Internet security refers to the practices and technologies used to protect computers, networks, programs, and data from unauthorized access, attack, or damage
  • Importance: As the Internet has become an essential part of personal and business life, securing online assets and information has become crucial
  • Threats: Common Internet security threats include viruses, malware, phishing, hacking, and denial-of-service attacks

2. Firewalls

  • Definition: A firewall is a network security system that monitors and controls incoming and outgoing network traffic based on predetermined security rules
  • Types: Network-based firewalls (protect an entire network) and host-based firewalls (protect individual computers)
  • Functions: Firewalls can block unauthorized access, filter traffic based on IP addresses or ports, and log network activity for analysis and auditing

3. Internet Security Management Concepts

  • Risk assessment: Identifying and evaluating potential security risks to an organization’s network and data
  • Security policies: Establishing clear guidelines and rules for acceptable use of an organization’s computing resources and data
  • Access control: Implementing measures to restrict access to sensitive data and systems, such as user authentication, passwords, and permissions
  • Encryption: Converting data into a coded format to protect it from unauthorized access during transmission or storage
  • Intrusion detection and prevention: Monitoring network traffic for signs of unauthorized access or attacks, and taking action to prevent or mitigate damage
  • Incident response: Having a plan in place to quickly and effectively respond to security breaches or incidents
  • Employee training: Educating employees about security best practices, such as creating strong passwords, identifying phishing attempts, and handling sensitive data responsibly

4. Information Privacy

  • Definition: Information privacy refers to the right of individuals to control how their personal information is collected, used, and shared
  • Importance: As more personal information is collected and shared online, protecting privacy has become a critical concern for individuals and organizations
  • Privacy laws and regulations: Many countries have enacted laws and regulations to protect personal information, such as the General Data Protection Regulation (GDPR) in the European Union and the California Consumer Privacy Act (CCPA) in the United States
  • Privacy policies: Organizations that collect personal information should have clear privacy policies that explain what information is collected, how it is used, and with whom it is shared
  • Data protection measures: Organizations should implement appropriate technical and organizational measures to protect personal information from unauthorized access, use, or disclosure
  • Individual rights: Individuals should have the right to access, correct, and delete their personal information, as well as the right to object to its processing in certain circumstances

UNIT-IV: Introduction to Java and HTML Programming Basics

Introduction to Java

The JDK Directory Structure

  • The Java Development Kit (JDK) is organized into a directory structure.
  • Important directories include:
    • bin: Contains executable files, such as the Java compiler (javac) and the Java runtime (java).
    • lib: Contains library files used by the JDK tools.
    • src: Contains the source code of the Java API classes.

Java History

  • Java was developed by James Gosling and his team at Sun Microsystems (now owned by Oracle) in the mid-1990s.
  • Key milestones:
    • 1995: Java 1.0 released
    • 2004: Java 5.0 introduced generics and annotations
    • 2014: Java 8 introduced lambda expressions and the Stream API

Java Features

  • Platform independence: Java programs can run on any device with a Java Virtual Machine (JVM).
  • Object-oriented programming: Java is based on objects, classes, and inheritance.
  • Robustness: Java has strong typing and exception handling to prevent errors.
  • Security: Java provides a secure environment for executing code.
  • Automatic memory management: Java uses a garbage collector to automatically free unused memory.
  • Multithreading: Java supports concurrent execution of multiple threads.

Structure of a Java Program

  • A Java program consists of the following basic elements:
    • Package declaration (optional): package com.example;
    • Import statements (optional): import java.util.Scanner;
    • Class declaration: public class MyClass { ... }
    • Main method: public static void main(String[] args) { ... }

Compiling and Interpreting Applications

  • Java source code (.java files) is compiled into bytecode (.class files) using the Java compiler (javac).
  • The bytecode is then interpreted and executed by the Java Virtual Machine (JVM).
  • Example:
    // public class HelloWorld { public static void main(String[] args) { System.out.println("Hello, World!"); } }
    Compile: javac
    Run: java HelloWorld

Java Tokens

  • Keywords: Reserved words with predefined meanings, such as public, class, if, else.
  • Identifiers: Names given to variables, methods, classes, etc., following certain rules.
  • Literals: Fixed values, such as numbers (10, 3.14) or strings ("Hello").
  • Operators: Symbols that perform operations on operands, such as +, -, *, /.
  • Separators: Punctuation characters used in the structure of a program, such as {, }, ;.

Java Character Set

  • Java uses the Unicode character set, which includes a wide range of characters from various languages.
  • Special characters can be represented using escape sequences, such as \n for a new line or \t for a tab.

Keywords and Identifiers

  • Java has 50+ reserved keywords, such as public, class, if, else, while, int, boolean.
  • Identifiers are names given to variables, methods, classes, etc.
  • Rules for valid identifiers:
    • Must start with a letter, underscore (_), or dollar sign ($).
    • Can contain letters, digits, underscores, and dollar signs.
    • Cannot be a reserved keyword.
  • Examples of valid identifiers: myVariable, _count, $price.

Primitive Data Types Declarations

  • Java has eight primitive data types:
    • Integer types: byte, short, int, long
    • Floating-point types: float, double
    • Boolean type: boolean
    • Character type: char
  • Examples:
    int age = 25; double price = 9.99; boolean isStudent = true; char grade = 'A';
  1. Non-Primitive Data Types
    • Reference types: Classes, interfaces, and arrays.
    • The String class is used to represent a sequence of characters.
    • Examples:
    String name = "John Doe"; int[] numbers = {1, 2, 3, 4, 5};
  2. Operators and Expressions
    • Arithmetic operators: +, -, *, /, % (modulo)
    • Assignment operators: =, +=, -=, *=, /=, %=
    • Comparison operators: ==, !=, <, >, <=, >=
    • Logical operators: && (AND), || (OR), ! (NOT)
    • Bitwise operators: &, |, ^, ~, <<, >>
    • Examples:
    int result = 10 + 5; boolean isEqual = (x == y); int bitwise = a & b;
  3. Implicit and Explicit Type Conversions: The Cast Operator
    • Implicit type conversion (widening): Automatically converting a smaller data type to a larger data type.
    int x = 10; double y = x; // Implicit conversion from int to double
    • Explicit type conversion (narrowing): Manually converting a larger data type to a smaller data type using the cast operator.
    double x = 9.99; int y = (int) x; // Explicit conversion from double to int
  4. Control Statements: If-else-if statement and Switch-case
    • If-else-if statement: Executes different blocks of code based on multiple conditions.
    if (grade >= 90) { System.out.println("A"); } else if (grade >= 80) { System.out.println("B"); } else if (grade >= 70) { System.out.println("C"); } else { System.out.println("F"); }
    • Switch-case statement: Executes different cases based on the value of a variable.
    switch (dayNumber) { case 1: System.out.println("Monday"); break; case 2: System.out.println("Tuesday"); break; // ... default: System.out.println("Invalid day number"); }
  5. Loops: While, Do While and For
    • While loop: Executes a block of code repeatedly as long as a condition is true.
    int i = 1; while (i <= 5) { System.out.println(i); i++; }
    • Do-while loop: Similar to while loop, but the condition is checked after each iteration.
    int i = 1; do { System.out.println(i); i++; } while (i <= 5);
    • For loop: Executes a block of code a specific number of times.
    for (int i = 1; i <= 5; i++) { System.out.println(i); }
  6. Object Oriented Concepts: Abstraction and Encapsulation, Data Hiding
    • Abstraction: Focusing on the essential features of an object and hiding unnecessary details.
    • Encapsulation: Bundling data and methods into a single unit (class) and controlling access to them.
    • Data hiding: Restricting direct access to an object’s internal state and providing controlled access through methods.
  7. Introduction to Classes and Objects
    • A class is a blueprint or template for creating objects.
    • An object is an instance of a class, created using the new keyword.
    • Example:
    public class Car { // Fields (attributes) private String brand; private String model; // Methods public void startEngine() { // ... } } Car myCar = new Car();
  8. Access Controls
    • Access modifiers control the visibility and accessibility of classes, methods, and variables.
    • Four access modifiers in Java:
    • public: Accessible from anywhere.
    • private: Accessible only within the same class.
    • protected: Accessible within the same class, subclasses, and the same package.
    • Default (no modifier): Accessible within the same package.
  9. Implementation of Inheritance and Polymorphism
    • Inheritance: A mechanism where a class (subclass) inherits properties and methods from another class (superclass).
    • Polymorphism: The ability of an object to take on many forms, achieved through method overriding and dynamic method dispatch.
    • Example:
    public class Animal { public void makeSound() { System.out.println("Animal sound"); } } public class Cat extends Animal { @Override public void makeSound() { System.out.println("Meow"); } }
  10. Methods in Java
    • A method is a block of code that performs a specific task.
    • Methods have a name, return type, and optional parameters.
    • Example:
    public int addNumbers(int a, int b) { return a + b; }
  11. Access Modifiers
    • Access modifiers control the visibility and accessibility of methods.
    • The same four access modifiers used for classes and variables apply to methods.
  12. Constructors and its types
    • A constructor is a special method used to initialize objects.
    • It has the same name as the class and no return type.
    • Default constructor: A no-argument constructor automatically provided by Java if no constructor is defined.
    • Parameterized constructor: A constructor that accepts arguments to initialize object properties.
    • Constructor overloading: Having multiple constructors with different parameter lists.
    • Example:
    public class Person { private String name; private int age; // Default constructor public Person() { // ... } // Parameterized constructor public Person(String name, int age) { = name; this.age = age; } }

HTML Programming Basics

HTML Page Structure

  • An HTML document consists of the following basic elements:
    • <!DOCTYPE html>: Specifies the document type.
    • <html>: The root element of the HTML page.
    • <head>: Contains metadata and links to external resources.
    • <body>: Contains the visible content of the web page.
  • Example:
    html <!DOCTYPE html> <html> <head> <title>My Web Page</title> </head> <body> <h1>Welcome to my website!</h1> <p>This is a paragraph.</p> </body> </html>


  • Text formatting tags:
    • Headings: <h1> to <h6> represent different levels of headings.
    • Paragraphs: <p> defines a paragraph of text.
    • Bold: <strong> or <b> makes text bold.
    • Italic: <em> or <i> makes text italic.
  • Special characters and entities:
    • &lt;: Represents the less-than symbol (<).
    • &gt;: Represents the greater-than symbol (>).
    • &amp;: Represents the ampersand symbol (&).
  • Example:
    html ¨K50K ¨K51K ¨K52K

HTML Links

  • Hyperlinks are created using the <a> tag.
  • The href attribute specifies the destination URL.
  • Example:
    html <a href="">Visit</a> <a href="mailto:[email protected]">Send an email</a> <a href="#section1">Go to Section 1</a>

HTML Document Tables

  • Tables are created using the <table> tag.
  • <tr> defines a table row, <th> defines a table header, and <td> defines a table cell.
  • Example:
    html ¨K53K

HTML Frames (Deprecated)

  • Frames allow dividing a web page into multiple independent sections.
  • The <frame> tag defines a single frame, and the <frameset> tag defines the layout of frames.
  • Note: Frames are deprecated in HTML5 and should be avoided. Use <iframe> or alternative techniques instead.

HTML Images

  • Images are inserted using the <img> tag.
  • The src attribute specifies the URL of the image file.
  • The alt attribute provides alternative text for the image.
  • Example:
    html <img src="image.jpg" alt="A beautiful landscape" width="500" height="300">

UNIT-V: Web Publishing and Browsing


  • Web publishing: The process of creating and making content available on the World Wide Web.
  • Web browsing: Accessing and viewing web pages using a web browser.
  • Importance of web publishing and browsing in the digital era.

SGML (Standard Generalized Markup Language)

  • SGML is a meta-language used to define markup languages.
  • It provides a framework for creating structured documents.
  • HTML and XML are derived from SGML.

Web Hosting

  • Web hosting refers to the service of storing and serving web pages on a server.
  • Types of web hosting:
    • Shared hosting: Multiple websites share the same server resources.
    • Dedicated hosting: A single website has exclusive access to a server.
    • Virtual Private Server (VPS) hosting: A server is divided into multiple virtual servers.
    • Cloud hosting: Websites are hosted on a network of connected servers.
  • Factors to consider when choosing a web hosting provider:
    • Reliability, uptime, performance, security, and customer support.

HTML (Hypertext Markup Language)

  • HTML is the standard markup language used to create web pages.
  • It uses tags to structure and format content.
  • Example HTML structure:
    html <!DOCTYPE html> <html> <head> <title>My Web Page</title> </head> <body> <h1>Welcome to my website!</h1> <p>This is a paragraph.</p> </body> </html>

CGI (Common Gateway Interface)

  • CGI is a standard protocol for web servers to execute programs and generate dynamic content.
  • It allows web servers to interact with external applications or scripts.
  • CGI scripts can be written in various programming languages (e.g., Perl, Python, PHP).
  • Example CGI script (in Python): #!/usr/bin/env python print("Content-type: text/html\n") print("<html>") print("<head><title>CGI Example</title></head>") print("<body>") print("<h1>Hello, World!</h1>") print("</body>") print("</html>")

Document Interchange Standards

  • Standards for exchanging and representing structured documents.
  • Examples:
    • XML (eXtensible Markup Language): A markup language for creating structured documents.
    • JSON (JavaScript Object Notation): A lightweight data interchange format.
    • PDF (Portable Document Format): A file format for representing documents independently of software or hardware.

Components of Web Publishing

  • Content creation: Developing the text, images, and multimedia elements for a website.
  • Web design: Creating the visual layout and user interface of a website.
  • Web development: Coding and programming the functionality of a website.
  • Content management: Organizing, storing, and updating website content.
  • Web hosting: Storing and serving the website files on a web server.
  • Domain registration: Registering a unique domain name for the website.

Document Management

  • Document management systems (DMS) help organize, store, and retrieve electronic documents.
  • Key features of a DMS:
    • Version control, access control, search and retrieval, and collaboration tools.
  • Examples of DMS: Microsoft SharePoint, Google Drive, Dropbox.

Web Page Design Considerations and Principles

  • User-centered design: Focusing on the needs and expectations of the target audience.
  • Usability: Ensuring the website is easy to navigate and use.
  • Accessibility: Making the website accessible to people with disabilities.
  • Responsive design: Designing the website to adapt to different screen sizes and devices.
  • Visual hierarchy: Arranging elements to guide users’ attention and prioritize information.
  • Consistency: Maintaining a consistent look and feel throughout the website.
  • Performance optimization: Minimizing page load times and improving overall performance.
  1. Search and Meta Search Engines
    • Search engines: Tools that help users find information on the web by indexing and ranking web pages.
    • Examples: Google, Bing, Yahoo.
    • Meta search engines: Search tools that aggregate and combine results from multiple search engines.
    • Examples: Dogpile, Metacrawler, Startpage.
    • Search engine optimization (SEO): Techniques to improve a website’s visibility and ranking in search engine results.
  2. WWW (World Wide Web)
    • The World Wide Web is a system of interconnected hypertext documents accessible via the Internet.
    • It is based on three key technologies:
    • HTML: The markup language for creating web pages.
    • URL (Uniform Resource Locator): The address used to locate web resources.
    • HTTP (Hypertext Transfer Protocol): The protocol for transmitting web pages.
  3. Browser
    • A web browser is a software application used to access and view websites.
    • Popular web browsers: Google Chrome, Mozilla Firefox, Apple Safari, Microsoft Edge.
    • Key functionalities of a web browser:
    • Rendering HTML and CSS, executing JavaScript, handling user interactions, and managing cookies and history.
  4. HTTP (Hypertext Transfer Protocol)
    • HTTP is the protocol used for communication between web browsers and servers.
    • It defines how messages are formatted and transmitted over the web.
    • HTTP methods:
    • GET: Retrieves a resource from the server.
    • POST: Submits data to be processed by the server.
    • PUT: Updates an existing resource on the server.
    • DELETE: Deletes a resource from the server.
    • HTTP status codes:
    • 200 OK: The request was successful.
    • 404 Not Found: The requested resource was not found.
    • 500 Internal Server Error: An error occurred on the server.
  5. Publishing Tools
    • Software applications used to create and publish web content.
    • Examples:
    • Content Management Systems (CMS): WordPress, Drupal, Joomla.
    • Web development frameworks: Ruby on Rails, Django, Laravel.
    • WYSIWYG (What You See Is What You Get) editors: Adobe Dreamweaver, Microsoft Expression Web.
    • Static site generators: Jekyll, Hugo, Gatsby.