Advanced Computer Science

Class 11 · Ages 16–17
And He taught man that which he knew not. (96:5)
Data Structures · Algorithms · DBMS · Networks · OS · Theory of Computation · Compiler Design · AI · Cybersecurity · Computer Graphics · Islamic Ethics

Learning Objectives

Topic 1 Advanced Data Structures

Beyond the Basics

In this topic, we explore advanced data structures that are essential for solving complex problems efficiently. These structures are used in real-world applications like databases, search engines, and operating systems.

Key Data Structures

  • 🔗 Linked Lists – Dynamic linear data structures with efficient insertion and deletion. Singly, doubly, and circular linked lists.
  • 🌳 Trees – Hierarchical data structures. Binary trees, binary search trees, AVL trees, B-trees, tries.
  • 📚 Heaps – Specialized trees for priority queues. Min-heap, max-heap, heap sort.
  • 🔢 Hash Tables – Key-value stores with O(1) average lookup. Hash functions, collision resolution.
  • 📊 Graphs – Networks of nodes and edges. Directed, undirected, weighted, adjacency list/matrix.
  • 📋 Stacks & Queues – Fundamental linear structures for LIFO and FIFO operations.
🔗 Linked Lists 🌳 Trees 📚 Heaps 🔢 Hash Tables 📊 Graphs 📋 Stacks/Queues
Advanced Data Structures
Fun Fact!

Google's PageRank algorithm uses graph data structures to rank web pages. The web is essentially a massive graph!

Try This!

Implement a Binary Search Tree in Python:

1. Create a Node class with value, left, and right.
2. Implement insertion, search, and traversal (in-order, pre-order, post-order).
3. Test with a list of numbers.

You're building a fundamental data structure!

Activity

Compare the performance of different data structures.

For each operation (insert, search, delete):
1. Measure the time for arrays, linked lists, binary search trees, and hash tables.
2. Use datasets of different sizes (100, 1000, 10000).
3. Create a chart showing the performance differences.

Which data structure is best for which operation?

Reflect

Allah's creation is filled with structure and order. The Qur'an says: "And everything with Him is by measure." (13:8)

Data structures reflect this divine order by organizing information in efficient ways. When we design data structures, we are imitating the order Allah has placed in the universe.

Key Takeaway

Advanced data structures include linked lists, trees, heaps, hash tables, graphs, stacks, and queues. Each has strengths and weaknesses for different applications. Choosing the right data structure is critical for efficient algorithm design.

Topic 2 Algorithms: Design & Analysis

Algorithmic Thinking

Algorithms are the heart of computer science. In this topic, we will learn how to design efficient algorithms and analyze their performance using Big-O notation.

Algorithm Paradigms

  • 🧠 Divide and Conquer – Break a problem into smaller subproblems, solve recursively, and combine. Examples: Merge sort, Quick sort, Binary search.
  • 📈 Dynamic Programming – Solve subproblems once and store their solutions. Examples: Fibonacci, Knapsack, Longest Common Subsequence.
  • 🔄 Greedy Algorithms – Make the locally optimal choice at each step. Examples: Huffman coding, Dijkstra's algorithm.
  • 🌳 Backtracking – Explore all solutions by building candidates and abandoning them if invalid. Examples: N-Queens, Sudoku, Maze solving.
  • 🔍 Graph Algorithms – Traversal, shortest paths, and connectivity. Examples: DFS, BFS, Dijkstra, Bellman-Ford, Floyd-Warshall.
🧠 Divide & Conquer 📈 DP 🔄 Greedy 🌳 Backtracking 🔍 Graphs
Algorithm Paradigms
Fun Fact!

The term "algorithm" comes from the 9th-century Persian mathematician Al-Khwarizmi, who wrote a book on algebra and arithmetic.

Try This!

Implement and compare sorting algorithms:

1. Implement Merge Sort, Quick Sort, and Insertion Sort.
2. Test them with arrays of different sizes.
3. Compare their time complexity and performance.

What patterns do you notice?

Activity

Solve a classic algorithmic problem:

Choose one:
1. Traveling Salesman Problem (TSP) – find the shortest route visiting all cities.
2. Knapsack Problem – maximize value within a weight limit.
3. N-Queens Problem – place N queens on an N×N chessboard without attacking each other.

Implement your solution and analyze its complexity.

Reflect

Algorithms teach us systematic problem-solving. The Qur'an says: "And We have made everything with measure." (54:49)

Just as algorithms follow precise steps, the universe follows divine laws. When we design algorithms, we are learning from the order Allah has created.

Key Takeaway

Algorithm design includes paradigms like divide and conquer, dynamic programming, greedy, backtracking, and graph algorithms. Understanding these paradigms helps you solve complex problems efficiently and correctly.

Topic 3 Database Management Systems (DBMS)

Managing Data at Scale

Database Management Systems are software systems that store, organize, and manage data efficiently. They are the backbone of almost every modern application.

Key Concepts

  • 📊 Relational Model – Data organized in tables with rows and columns. Keys: Primary Key, Foreign Key, Candidate Key.
  • 📝 SQL (Structured Query Language) – The standard language for relational databases. DDL, DML, DCL, and TCL commands.
  • 🔗 Normalization – Organize data to reduce redundancy and improve integrity. 1NF, 2NF, 3NF, BCNF.
  • 📊 Transactions – ACID properties (Atomicity, Consistency, Isolation, Durability).
  • 🗄️ NoSQL – Non-relational databases for unstructured data. Document stores (MongoDB), key-value (Redis), graph (Neo4j).
  • 🔒 Indexing – Improve query performance with data structures like B-trees.
📊 Relational 📝 SQL 🔗 Normalization 📊 ACID 🗄️ NoSQL 🔒 Indexing
DBMS Core Concepts
Fun Fact!

The first relational database system, IBM's System R, was developed in the 1970s. It led to the creation of SQL and the modern database industry.

Try This!

Design a database for a library management system:

Tables: Books, Members, Loans, Categories.
Write SQL to:
1. Find all books borrowed by a member.
2. Find overdue books.
3. Add a new book.

You're designing a real-world database!

Activity

Normalize a database design.

Start with an unnormalized table: e.g., Student(ID, Name, Address, Courses, Grades).

Apply normalization steps:
1. 1NF – Remove repeating groups.
2. 2NF – Remove partial dependencies.
3. 3NF – Remove transitive dependencies.

Show your final normalized design.

Reflect

Allah's creation is organized and efficient. The Qur'an says: "And We have made everything with measure." (54:49)

Database design teaches us about organization and efficiency. When we design databases well, we are following the divine principle of order and efficiency.

Key Takeaway

DBMS manages data efficiently using the relational model. SQL is the standard language for querying and managing data. Normalization reduces redundancy and improves integrity. ACID properties ensure transaction reliability. NoSQL databases handle unstructured data.

Topic 4 Computer Networks

Connecting the World

Computer networks enable communication and data sharing between devices. This topic covers the principles, protocols, and technologies that power the internet and modern communication.

Key Topics

  • 🌐 OSI Model – 7-layer framework for network communication. Physical, Data Link, Network, Transport, Session, Presentation, Application.
  • 📡 TCP/IP – The protocol suite of the internet. IP addressing, subnetting, routing.
  • 🔄 Routing Protocols – How data finds its way across networks. RIP, OSPF, BGP.
  • 🔒 Network Security – Protecting data in transit. Encryption, SSL/TLS, firewalls, VPNs.
  • 📶 Wireless & Mobile – Wi-Fi, cellular networks, Bluetooth.
🌐 OSI 📡 TCP/IP 🔄 Routing 🔒 Security 📶 Wireless
Network Fundamentals
Fun Fact!

Vint Cerf and Bob Kahn developed TCP/IP in the 1970s. They are often called the "fathers of the internet."

Try This!

Trace a packet's journey:

1. Use the "traceroute" command (tracert on Windows) to see the path from your computer to a website.
2. Count the number of routers (hops).
3. Note the IP addresses and response times.

What do you notice about the path?

Activity

Design a network topology.

Choose a scenario: e.g., a small office, a school campus, or a data center.

Create a diagram showing:
1. Devices (computers, servers, switches, routers).
2. Connections (cables or wireless).
3. IP addressing scheme.
4. Security measures (firewalls).

Explain your design choices.

Reflect

Networks connect people across the world. The Qur'an says: "O mankind, indeed We have created you from male and female and made you peoples and tribes that you may know one another..." (49:13)

The internet is a powerful tool for connection and understanding. Use it to build bridges and share knowledge with others.

Key Takeaway

Computer networks enable global communication. The OSI model and TCP/IP are foundational frameworks. Routing protocols direct data packets. Network security protects data in transit. Understanding networks is essential for any computer scientist.

Topic 5 Operating Systems

The System Manager

An operating system is the software that manages computer hardware and provides a platform for applications. This topic explores the internal workings of operating systems.

Key Concepts

  • 🔄 Process Management – Scheduling, synchronization, and deadlock handling. Process states, scheduling algorithms, semaphores.
  • 🧠 Memory Management – Allocation, paging, segmentation, virtual memory. Page replacement algorithms, fragmentation.
  • 📂 File Systems – Organizing and managing data on storage devices. FAT, NTFS, ext4, inodes, journaling.
  • 🔌 I/O Management – Interfacing with peripherals and devices. Buffering, caching, device drivers.
  • 🔒 Security – Protecting data and resources from unauthorized access. User authentication, access control, sandboxing.
🔄 Processes 🧠 Memory 📂 File Systems 🔌 I/O 🔒 Security
Operating System Functions
Fun Fact!

Unix was developed in 1969 and is the foundation for many modern operating systems, including Linux and macOS.

Try This!

Explore process management in Linux:

1. Use the ps command to list running processes.
2. Use top or htop to see CPU and memory usage.
3. Use kill to terminate a process.

You're using OS-level tools!

Activity

Simulate a CPU scheduler.

Implement:
1. FCFS (First-Come, First-Served)
2. SJF (Shortest Job First)
3. Round Robin
4. Priority Scheduling

Compare the performance of each algorithm using metrics like waiting time and turnaround time.

Reflect

Operating systems manage resources efficiently and fairly. The Qur'an says: "And give the measure and weight with justice..." (6:152)

Just as an OS manages resources, we should manage our time, money, and talents with wisdom and justice. Fairness and efficiency are values we should cultivate.

Key Takeaway

Operating systems manage hardware and provide a platform for applications. Key functions include process management, memory management, file systems, I/O management, and security. Understanding OS internals helps you write better, more efficient code.

Topic 6 Theory of Computation

What is Computation?

Theory of Computation is the study of the fundamental capabilities and limitations of computers. It answers deep questions about what can be computed and how efficiently.

Key Concepts

  • 🔤 Automata Theory – Abstract machines and formal languages. Finite automata (DFA, NFA), regular expressions, context-free grammars.
  • 🧠 Computability Theory – What problems can be solved by computers? Turing machines, Church-Turing thesis, undecidable problems.
  • 📊 Complexity Theory – How efficiently can problems be solved? P vs NP, NP-complete problems, complexity classes.
  • 📝 Formal Languages – Classification of languages: regular, context-free, context-sensitive, recursive.
🔤 Automata 🧠 Computability 📊 Complexity 📝 Formal Languages
Theory of Computation
Fun Fact!

The "P vs NP" problem is one of the most famous unsolved problems in computer science. The Clay Mathematics Institute has offered a $1 million prize for its solution.

Think About It

Can a computer solve every problem?

The Theory of Computation shows that some problems are undecidable – no computer program can solve them. The classic example is the Halting Problem: can a program determine if another program will stop or run forever?

It's impossible to write such a program!

Activity

Design a finite automaton.

Choose a language:
1. Strings that end with "01".
2. Strings with an even number of 0s.
3. Strings that start with "a" and end with "b".

Draw the DFA with states, transitions, and accepting states. Test it with sample strings.

Reflect

The Theory of Computation reveals the limits of human knowledge. The Qur'an says: "And we have not been given of knowledge except a little." (17:85)

This field teaches us humility – there are things we cannot know or compute. This reminds us of our dependence on Allah, who knows everything.

Key Takeaway

Theory of Computation explores the limits of computing. Automata theory studies abstract machines and formal languages. Computability theory asks what can be computed. Complexity theory studies the efficiency of computation. These concepts are fundamental to understanding computer science.

Topic 7 Artificial Intelligence

Machine Intelligence

Artificial Intelligence (AI) is the field of creating intelligent machines that can think, learn, and solve problems like humans. This topic covers the core concepts and techniques of AI.

Key Topics

  • 🧠 Machine Learning – Algorithms that learn from data. Supervised, unsupervised, and reinforcement learning.
  • 🔬 Deep Learning – Neural networks with multiple layers. CNN, RNN, transformers, GANs.
  • 🗣️ Natural Language Processing – Understanding and generating human language. NLP tasks: translation, sentiment analysis, text generation.
  • 👁️ Computer Vision – Interpreting and understanding visual information. Image classification, object detection, segmentation.
  • 🤖 Robotics – AI in physical systems for perception and action.
  • 📊 AI Ethics – Fairness, transparency, accountability, and privacy.
🧠 ML 🔬 DL 🗣️ NLP 👁️ CV 🤖 Robotics 📊 Ethics
Artificial Intelligence
Fun Fact!

The term "Artificial Intelligence" was coined by John McCarthy at the Dartmouth Conference in 1956. The field has grown enormously since then.

Try This!

Build a simple machine learning model:

1. Use Python with scikit-learn or TensorFlow.
2. Load a dataset (e.g., iris flowers or house prices).
3. Train a model and evaluate its accuracy.

You've built an AI model!

Activity

Explore a recent AI breakthrough.

Choose one:
1. ChatGPT / Large Language Models
2. Generative AI (DALL-E, Stable Diffusion)
3. AlphaGo or AlphaZero

Research:
1. How does it work?
2. What are its capabilities and limitations?
3. What are the ethical considerations?

Present your findings.

Reflect

AI reflects the intelligence that Allah has given us. The Qur'an says: "And He taught Adam the names – all of them." (2:31)

When we create AI, we are using the gift of intellect that Allah has given us. We must ensure that AI is used for good and justice, and that it serves the benefit of all humanity.

Key Takeaway

Artificial Intelligence creates intelligent systems. Key areas include machine learning, deep learning, NLP, computer vision, robotics, and AI ethics. Understanding AI is essential for the future of technology and society.

Topic 8 Cybersecurity & Ethical Hacking

Protecting the Digital World

Cybersecurity is the practice of protecting systems, networks, and data from digital attacks. This topic covers the principles, techniques, and tools used to secure information systems.

Key Topics

  • 🔐 Cryptography – Securing communication with encryption. Symmetric (AES) and asymmetric (RSA) encryption, hashing.
  • 🛡️ Network Security – Protecting data in transit. Firewalls, IDS/IPS, VPNs, SSL/TLS.
  • 💻 Application Security – Securing software from vulnerabilities. OWASP Top 10, secure coding practices.
  • 🕵️ Ethical Hacking – Penetration testing to find and fix vulnerabilities. Tools: Nmap, Wireshark, Metasploit, Burp Suite.
  • 📋 Incident Response – Responding to and recovering from security breaches.
  • ⚖️ Cyber Laws – Legal frameworks for cybercrime and data protection.
🔐 Crypto 🛡️ Network 💻 App Security 🕵️ Ethical Hacking 📋 Incident
Cybersecurity
Fun Fact!

RSA encryption, one of the most widely used encryption algorithms, was invented in 1977 by Ron Rivest, Adi Shamir, and Leonard Adleman – hence the name RSA.

Try This!

Simulate a simple phishing attack:

1. Create a fake login page (educational purposes only!).
2. Demonstrate how phishing works and how to recognize it.
3. Discuss best practices for avoiding phishing.

Important: Only use this knowledge for ethical purposes!

Activity

Conduct a security audit.

Choose a small web application (e.g., a simple login system).

Identify:
1. SQL injection vulnerabilities.
2. XSS (Cross-Site Scripting) vulnerabilities.
3. Authentication weaknesses.
4. Recommendations for fixing each issue.

Write a security report.

Reflect

Allah is the Protector. The Qur'an says: "And Allah is the best Protector, and He is the Most Merciful of the merciful." (12:64)

Cybersecurity is a way of protecting ourselves and others. It is a responsibility to safeguard people's data and privacy. Use your skills to protect and defend, never to harm.

Key Takeaway

Cybersecurity protects systems and data from attacks. Key areas include cryptography, network security, application security, ethical hacking, and incident response. Cybersecurity is a critical field for protecting privacy, integrity, and availability of information.

Topic 9 Islamic Ethics in Technology

Technology and Islamic Values

As technology becomes more powerful and pervasive, it's essential to consider its ethical implications from an Islamic perspective. This topic explores how Islamic principles guide the development and use of technology.

Key Ethical Principles

  • 🤲 Tawhid (Oneness of Allah) – Technology should be used for purposes that please Allah and benefit humanity. "And We have not created the heavens and the earth and everything between them in play." (21:16)
  • ⚖️ Justice ('Adl) – Technology must be fair and equitable for all people. "And act justly. Indeed, Allah loves those who act justly." (49:9)
  • 🔒 Privacy (Haya) – Protecting people's personal data is a trust. "And do not spy..." (49:12)
  • 🤝 Beneficence (Ihsan) – Use technology to help and benefit others. "The best of people are those who are most beneficial to others." (Hadith)
  • 📚 Knowledge (Ilm) – Pursuing technological knowledge is a noble goal. "Seeking knowledge is an obligation upon every Muslim." (Hadith)
🤲 Tawhid ⚖️ Justice 🔒 Privacy 🤝 Beneficence 📚 Knowledge
Islamic Principles for Technology
Fun Fact!

Islamic civilization has a rich history of technological innovation, including the development of algebra, optics, and mechanical devices.

Story: The Ethical Developer

A developer named Fatima was asked to build an app that tracked users' location for targeted advertising. She realized that the app would collect data without proper consent.

She spoke to her manager: "I believe this app would violate users' privacy. Could we redesign it to be more transparent and give users control over their data?"

Her manager agreed to make changes. The app was successful because users trusted it.

The lesson: Ethical developers speak up for what's right. They build technology that respects privacy and dignity.

Activity

Write a code of ethics for a technology company.

Include:
1. Data privacy and user consent.
2. Fairness and non-discrimination.
3. Transparency and accountability.
4. Environmental responsibility.
5. Community service and social impact.

Share your code with the class.

Reflect

Allah is the All-Knowing and All-Wise. The Qur'an says: "And whoever has faith in Allah, He guides his heart." (64:11)

As technologists, we have a responsibility to use our skills in ways that please Allah and benefit humanity. Let us be leaders in ethical technology, guided by Islamic values.

Key Takeaway

Islamic ethics guide the development and use of technology. Key principles include Tawhid, justice, privacy, beneficence, and the pursuit of knowledge. As Muslims, we must ensure that technology serves humanity and is developed with integrity and responsibility.

Class 11 Computer Science – Complete!

You've explored advanced data structures, algorithms, database management systems, computer networks, operating systems, theory of computation, artificial intelligence, cybersecurity, and Islamic ethics in technology. You are now equipped with a strong foundation for higher-level computer science studies and a career in technology! May Allah bless your learning and help you use technology to serve humanity and please Him.

Topic 1 Topic 2 Topic 3 Topic 4 Topic 5 Topic 6 Topic 7 Topic 8 Topic 9