22
1. Explain the concept of Object-Oriented Programming (OOP) in Java.
Java is a fully object-oriented programming language that follows the core principles of Object-Oriented Programming (OOP): encapsulation, inheritance, polymorphism, and abstraction. In Java, everything is treated as an object, which makes it easy to model real-world scenarios. Encapsulation is achieved using access modifiers and getter/setter methods, ensuring that data is protected from unauthorized access. Inheritance allows...
#Single Inheritance
using System; class Vehicle {
public void Start() {
Console.WriteLine("Vehicle has started."); } }
class Car : Vehicle { public void Drive() {
Console.WriteLine("Car is driving."); } }
class Program { static void Main(string[] args) {
Car myCar = new Car(); myCar.Start(); myCar.Drive(); } }
#Multilevel Inheritance
using System; class Animal {
...print() – displays output.
end=" " – prevents new line after print.
sep="," – separates items with a character.
input() always returns a string.
Add strings = concatenation ("5" + "10" = "510").
Use int() for number input:
➤ num = int(input("Enter a number: "))
int, float, str, bool are common types.
Use type(variable) to check the type.
What is a Security Mechanism?
A security mechanism is a method, tool, or procedure used to protect systems, networks, software, and data from unauthorized access, damage, or theft. It enforces security policies and ensures confidentiality, integrity, and availability (often called the CIA triad) of information.
Common Types of Security Mechanisms:
1. Authentication
Verifies the identity of a user or system.
Examples: Passwords, biometric scans, two-factor authentication (2FA).
2. Authorization
Determines
In game programming, transformation refers to the process of changing an object's position, rotation, or scale within a game world. These changes are typically represented using mathematics, especially vectors and matrices.
There are three main
types of transformations:
1. Translation
Moves an object from one place to another.
Example: Moving a player forward by 5 units.
In 2D/3D games, this is often done by adding a vector to the object’s current position.
2. Rotation
Rotates an object around a point
Artificial Intelligence (AI) is the simulation of human intelligence in machines that are programmed to think, learn, and make decisions. AI systems can perform tasks that typically require human intelligence, such as recognizing speech, understanding language, solving problems, and making predictions.
✅ Main Categories of AI
AI can be categorized in two main ways:
I. Based on Capabilities
1. Narrow AI (Weak AI)
Designed for a specific task
Examples: Siri, Google Assistant, facial recognition systems
2.
Project Stakeholder – Short Note:
A project stakeholder is any individual, group, or organization that has an interest in or is affected by the outcome of a project. Stakeholders can be internal (like team members, managers, or departments) or external (such as clients, suppliers, investors, or regulatory bodies). They may influence project decisions, provide resources, or be impacted by project deliverables. Effective communication and management of stakeholders are crucial to a project's success,
1.Verification checks whether the product is built right.
Validation checks whether the right product is built.
2.Verification ensures the software meets specifications.
Validation ensures the software meets user needs.
3.Verification is a static process (no code execution).
Validation is a dynamic process (involves running code).
4.Verification is done during development phases.
Validation is done after development (testing phase).
5.Verification involves reviews, walkthroughs, inspections.
Validation involves
Everything you need to recall about Large Language Models — in one page.
A Large Language Model (LLM) is a deep learning model trained on vast amounts of text data to understand, generate, and manipulate human language.
Examples: GPT-4, Claude, LLaMA, Gemini, Mistral, Falcon
Core Technology: Transformer Architecture
| Component | Description |
|---|---|
| Tokenizer | Converts text → tokens (subwords, words) → numerical input |