Đại học Kinh tế Quốc dân|Trường Công nghệ
    |
    🇻🇳 Tiếng Việt
    🇬🇧 English

    KHOA CÔNG NGHỆ THÔNG TIN

    Faculty of Information Technology

      CÔNG NGHỆ THÔNG TIN — CHEATSHEET

      1. NỀN TẢNG LẬP TRÌNH
      Nhập môn CNTT CNTT1116
      • Biểu diễn dữ liệu: Binary (0,1) • Octal (0-7) • Hex (0-F) • 2's complement • IEEE 754 • ASCII/Unicode
      • Tổ chức máy tính: CPU (ALU, CU, Register) • Memory hierarchy • Bus system • Von Neumann
      • Thuật toán: Đúng đắn • Dừng • Xác định • Phổ dụng • Độ phức tạp O(n)
      # Python cơ bản - Tính giai thừa đệ quy def factorial(n): return 1 if n <= 1 else n * factorial(n-1)
      Cơ sở lập trình C CNTT1128
      • Kiểu dữ liệu: int (2-4B) • float (4B) • double (8B) • char (1B) • array • string
      • Điều khiển: if-else • switch • for • while • do-while • break/continue
      • Con trỏ & Bộ nhớ: Khai báo (*ptr) • Địa chỉ (&var) • malloc/free • Pointer arithmetic
      typedef struct Node { int data; struct Node* next; } Node; Node* head = (Node*)malloc(sizeof(Node));
      Lỗi thường gặp: Buffer overflow • Memory leak • Dangling pointer
      Cấu trúc dữ liệu & Giải thuật TIHT1101
      CTDLInsertDeleteSearchSpace
      ArrayO(n)O(n)O(n)/O(logn)O(n)
      Linked ListO(1)O(1)O(n)O(n)
      BSTO(logn)O(logn)O(logn)O(n)
      Hash TableO(1)O(1)O(1)O(n)
      • Linear: Stack (LIFO) • Queue (FIFO) • Deque • Circular Queue
      • Tree: Binary • BST • AVL • Red-Black • B-Tree • Heap
      • Sort: Bubble/Selection O(n²) • Quick/Merge/Heap O(nlogn)
      Lập trình hướng đối tượng CNTT1131
      • 4 tính chất OOP: Encapsulation • Inheritance • Polymorphism • Abstraction
      • Class components: Constructor/Destructor • Static members • Virtual function
      class Shape { public: virtual double area() = 0; }; class Circle : public Shape { double area() override { return 3.14 * r * r; } }; Design Principles: SOLID • DRY • KISS • YAGNI
      2. HỆ THỐNG MÁY TÍNH & HẠ TẦNG
      Hệ điều hành CNTT1107
      • Process: New → Ready → Running → Waiting → Terminated • PCB
      • Thread: User vs Kernel • Many-to-One/Many • Thread pool
      • Scheduling: FCFS • SJF • Round Robin • Priority • Multilevel
      • Synchronization: Race condition • Mutex • Semaphore • Monitor
      • Deadlock: 4 conditions • Prevention • Avoidance • Detection
      sem_wait(&mutex); // P operation - enter critical // critical section code sem_post(&mutex); // V operation - exit
      Memory: Paging • Segmentation • Virtual Memory • Page replacement
      Kiến trúc máy tính CNTT1112
      ComponentFunctionSpeedSize
      RegisterCPU storage1 cycle32-64 bits
      L1 CacheInst+Data1-2 cycles32-64 KB
      L2 CacheUnified10 cycles256KB-1MB
      RAMMain memory100 cycles4-32 GB
      • Pipeline: IF → ID → EX → MEM → WB (5 stages)
      • Hazards: Structural • Data (RAW, WAR, WAW) • Control
      Công nghệ ảo hóa CNTT1145
      • Virtualization: Full • Para • Hardware-assisted • OS-level
      • Hypervisor: Type 1 (ESXi, Hyper-V) • Type 2 (VirtualBox)
      • Container: Docker • Kubernetes • Images • Volumes
      FROM node:14-alpine WORKDIR /app COPY . . RUN npm install CMD ["node", "server.js"] K8s: Pods • Services • Deployments • ConfigMaps • Ingress
      Điện toán đám mây CNTT1167
      Service Models:
      • IaaS: VMs, Storage
      • PaaS: Runtime
      • SaaS: Applications
      AWS Services:
      • EC2: Compute
      • S3: Storage
      • RDS: Database
      Cloud patterns: Auto-scaling • Load balancing • CDN • Multi-region
      3. MẠNG MÁY TÍNH & BẢO MẬT
      Mạng máy tính CNTT1114
      OSI LayerTCP/IPProtocolsDevices
      ApplicationApplicationHTTP, FTP, DNSGateway
      PresentationSSL/TLS-
      SessionNetBIOS-
      TransportTransportTCP, UDP-
      NetworkInternetIP, ICMP, ARPRouter
      Data LinkNetwork AccessEthernet, WiFiSwitch
      PhysicalCable, FiberHub
      Private IP: 10.0.0.0/8 • 172.16.0.0/12 • 192.168.0.0/16 Subnet: /24=256 • /25=128 • /26=64 • /27=32 • /28=16 VLSM calculation: 192.168.1.0/24 → 4 subnets: /26 each
      • TCP: 3-way handshake (SYN→SYN-ACK→ACK) • Reliable • Flow control
      • UDP: Connectionless • Fast • No guarantee • DNS, DHCP, VoIP
      • Routing: Static • Dynamic (RIP, OSPF, BGP)
      Quản trị mạng CNTT1121
      • Config: VLAN (802.1Q) • Trunking • STP (prevent loops) • VTP • EtherChannel
      • Routing: OSPF areas • BGP AS • EIGRP • Static routes • Policy-based routing
      • Monitor: SNMP v1/v2c/v3 • NetFlow • Syslog • Nagios • Zabbix • MRTG
      • QoS: Traffic shaping • Policing • DSCP marking • Priority queuing
      iptables -A INPUT -p tcp --dport 22 -s 192.168.1.0/24 -j ACCEPT iptables -A INPUT -m state --state ESTABLISHED,RELATED -j ACCEPT iptables -P INPUT DROP # Default deny policy
      An toàn bảo mật thông tin CNTT1168
      Cryptography:
      • Symmetric: AES-256, 3DES
      • Asymmetric: RSA, ECC
      • Hash: SHA-256, bcrypt
      • PKI: X.509, CA, CRL
      Attacks & Defense:
      • Web: SQLi, XSS, CSRF
      • Network: DDoS, MitM
      • System: Buffer overflow
      • Social: Phishing
      Defense: Firewall • IDS/IPS • WAF • SIEM • Zero trust
      Standards: ISO 27001 • NIST • OWASP Top 10 • PCI DSS
      IoT - Mạng kết nối vạn vật CNTT1154
      • Protocols: MQTT • CoAP • LoRaWAN • Zigbee • BLE • NB-IoT
      • Platforms: Arduino • ESP8266/ESP32 • Raspberry Pi
      Edge Computing • Fog Computing • Digital Twin • Time Series DB
      4. CƠ SỞ DỮ LIỆU & QUẢN TRỊ DỮ LIỆU
      Cơ sở dữ liệu TIKT1130
      • ER Model: Entity • Attributes • Relationship (1:1, 1:N, M:N)
      • Relational: Relations • Keys (primary, foreign, candidate)
      • SQL: DDL (CREATE, ALTER) • DML (SELECT, INSERT) • DCL (GRANT)
      • Normalization: 1NF • 2NF • 3NF • BCNF
      SELECT c.name, COUNT(o.id), SUM(o.total) FROM customers c LEFT JOIN orders o ON c.id = o.customer_id GROUP BY c.id HAVING COUNT(o.id) > 5 ORDER BY SUM(o.total) DESC;
      Joins: INNER • LEFT/RIGHT • FULL OUTER • CROSS • SELF
      Hệ quản trị CSDL CNTT1152
      ACIDDescriptionImplementation
      AtomicityAll or nothingTransaction log
      ConsistencyValid stateConstraints
      IsolationConcurrentLocking, MVCC
      DurabilityPermanentWAL, Checkpoint
      • Indexing: B-Tree (range) • B+Tree (leaf data) • Hash (equality) • Bitmap (low cardinality) • GiST • GIN
      • Concurrency Control: 2PL (growing/shrinking) • Timestamp ordering • Optimistic • MVCC
      • Recovery: Log-based • Shadow paging • ARIES protocol • Checkpointing
      Query optimization: Cost-based • Join algorithms • Statistics
      Phát hiện tri thức từ dữ liệu CNTT1181
      • KDD Process: Cleaning → Integration → Mining → Evaluation
      • Tasks: Classification • Clustering • Association • Regression
      • Algorithms: Decision Tree • k-means • Apriori • Neural Networks
      Association Rule: {Bread, Milk} → {Butter} Support = P(A∪B) = 3/5 = 60% Confidence = P(B|A) = 3/4 = 75% Lift = Confidence/P(B) = 0.75/0.8 = 0.94
      Lập trình phân tích dữ liệu CNTT1187
      import pandas as pd df = pd.read_csv('data.csv') df.groupby('category')['value'].agg(['mean','std']) df.pivot_table(values='sales', index='date', columns='product') pandas • numpy • matplotlib • seaborn • scikit-learn
      5. PHÁT TRIỂN ỨNG DỤNG WEB
      Thiết kế Web CNTT1165
      • HTML5: Semantic tags • Forms • Canvas • Audio/Video • Web Storage
      • CSS3: Flexbox • Grid • Animations • Media queries • Variables
      • JavaScript: DOM • Events • Promises • Async/await • ES6+
      • Responsive: Mobile-first • Viewport • Fluid grids • rem/em
      .container { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); } const data = await fetch('/api/data').then(r => r.json());
      Lập trình Web CNTT1188
      • Backend Frameworks: Node.js/Express • PHP/Laravel • Python/Django/FastAPI • Java/Spring Boot • Ruby/Rails • ASP.NET Core
      • API Design: RESTful (GET, POST, PUT, DELETE, PATCH) • GraphQL (query, mutation, subscription) • WebSocket • gRPC • OpenAPI/Swagger
      • Authentication: Session-based • Token-based (JWT) • OAuth 2.0 • OpenID Connect • SAML • Multi-factor (TOTP, SMS)
      • Database: SQL (MySQL, PostgreSQL, MSSQL) • NoSQL (MongoDB, Redis, Cassandra) • ORM/ODM (Sequelize, Mongoose, Prisma)
      app.use(cors()); app.use(express.json()); app.post('/api/users', async (req, res) => { const user = await User.create(req.body); res.status(201).json(user); });
      Security: Input validation • XSS protection • CSRF tokens • HTTPS
      Thương mại điện tử TIKT1129
      • E-commerce Models: B2C • B2B • C2C • O2O • Subscription
      • Features: Product catalog • Cart • Payment • Order tracking • Reviews
      • Security: PCI DSS • SSL/TLS • 3D Secure • Fraud detection
      Platforms: WooCommerce • Shopify • Magento • Payment: Stripe • PayPal
      Lập trình Java CNTT1153
      @RestController @RequestMapping("/api") public class UserController { @GetMapping("/users/{id}") public ResponseEntity getUser(@PathVariable Long id) { return ResponseEntity.ok(userService.findById(id)); }} Spring Boot • JPA • Maven • Microservices
      6. ỨNG DỤNG DI ĐỘNG & ĐA PHƯƠNG TIỆN
      Phát triển ứng dụng di động CNTT1157
      PlatformNativeCross-platformIDE
      AndroidKotlin/JavaFlutter, React NativeAndroid Studio
      iOSSwift/Obj-CFlutter, React NativeXcode
      • Android: Activity • Fragment • Service • Broadcast Receiver • Content Provider
      • Lifecycle: onCreate → onStart → onResume → onPause → onStop → onDestroy
      • iOS: UIViewController • Storyboard/SwiftUI • Auto Layout • Core Data
      • UI Patterns: Navigation drawer • Tab bar • RecyclerView • Pull to refresh
      @Composable fun UserProfile(user: User) { Card { Column { Text(user.name) } } }
      • Data Storage: SharedPreferences/UserDefaults • SQLite • Room/Core Data • Firebase Realtime DB • Realm
      • Networking: Retrofit (Android) • Alamofire (iOS) • REST APIs • WebSocket
      • Publishing: Google Play • App Store • Signing • App review • ASO
      Testing: Unit tests • UI tests (Espresso/XCTest) • Instrumentation • Firebase Test
      Công nghệ đa phương tiện CNTT1149
      • Digital Audio: Sampling rate (44.1/48/96 kHz) • Bit depth (16/24/32 bit) • Nyquist theorem • Quantization
      • Audio Formats: Lossless (WAV, FLAC, ALAC) • Lossy (MP3-320kbps, AAC, OGG Vorbis) • Codecs comparison
      • Digital Video: Frame rate (24/30/60/120 fps) • Resolution (HD 720p, FHD 1080p, 4K 2160p, 8K)
      • Video Compression: Codec families (H.264/AVC, H.265/HEVC, VP9, AV1) • Container formats (MP4, MKV, WebM)
      • Streaming: Progressive download • Adaptive bitrate (HLS, MPEG-DASH) • CDN • DRM • Live streaming protocols
      ffmpeg -i input.mp4 -c:v libx264 -crf 22 -c:a aac output.mp4 Tools: FFmpeg • OpenCV • WebRTC • MediaCodec
      Xử lý ảnh CNTT1166
      import cv2 img = cv2.imread('image.jpg') gray = cv2.cvtColor(img, cv2.COLOR_BGR2GRAY) edges = cv2.Canny(gray, 50, 150)
      • Operations: Filtering • Edge detection • Morphology • Histogram
      • Features: SIFT • SURF • ORB • HOG • Haar cascades
      • Applications: Face detection • OCR • Object tracking • AR
      7. PHÂN TÍCH THIẾT KẾ & QUẢN LÝ DỰ ÁN
      Phân tích và thiết kế hệ thống CNTT1117
      • UML Diagrams: Structure (Class, Component, Deployment, Package) • Behavior (Use Case, Activity, Sequence, State, Communication)
      • Design Patterns: Creational (Singleton, Factory, Builder) • Structural (Adapter, Decorator, Facade) • Behavioral (Observer, Strategy, Command)
      • SDLC Models: Waterfall (sequential) • Iterative • Spiral (risk-driven) • Agile (Scrum, Kanban) • DevOps (CI/CD)
      • Requirements: Functional (what system does) • Non-functional (performance, security, usability) • Use cases • User stories
      public class Database { // Singleton Pattern private static Database instance; private Database() {} public static synchronized Database getInstance() { if (instance == null) instance = new Database(); return instance; }}
      System Design: Modularity • Coupling (loose) • Cohesion (high) • Separation of concerns • DRY • SOLID
      Phân tích nghiệp vụ CNTT1137
      Analysis ToolPurposeOutput
      SWOTStrategic planningS-W-O-T matrix
      BPMNProcess modelingProcess diagram
      DFDData flowContext/Level 0-n
      Use CaseRequirementsActors & scenarios
      • Requirements Gathering: Interviews • Surveys • Observation • Document analysis • Workshops • Prototyping
      • Documentation: BRD (Business Requirements) • FRD (Functional) • TRD (Technical) • SRS (Software Requirements)
      Quản lý dự án CNTT CNTT1159
      • Project Phases: Initiation → Planning → Execution → Monitoring → Closing
      • Knowledge Areas: Integration • Scope • Schedule • Cost • Quality • Resource • Communication • Risk • Procurement • Stakeholder
      • Estimation: Expert judgment • Analogous • Parametric • Three-point (O+4M+P)/6 • Function points • Story points
      • Agile/Scrum: Product Backlog • Sprint (1-4 weeks) • Daily Standup • Sprint Review • Retrospective • Velocity
      CPM: Longest path • Zero float • Determines project duration
      Tools: MS Project • JIRA • Trello • Gantt chart • Burndown chart • Kanban board
      8. TRÍ TUỆ NHÂN TẠO & CÔNG NGHỆ MỚI
      Machine Learning CNTT1140
      ML TypeAlgorithmsUse Cases
      SupervisedLinear/Logistic Regression, SVM, Random ForestClassification, Regression
      Unsupervisedk-means, DBSCAN, PCAClustering, Dim reduction
      ReinforcementQ-Learning, DQN, PPOGame AI, Robotics
      Deep LearningCNN, RNN, TransformerVision, NLP
      from sklearn.ensemble import RandomForestClassifier X_train, X_test, y_train, y_test = train_test_split(X, y) model = RandomForestClassifier().fit(X_train, y_train) accuracy = model.score(X_test, y_test)
      • Feature Engineering: Selection • Extraction • Scaling • Encoding
      • Evaluation: Accuracy • Precision • Recall • F1 • ROC-AUC • Cross-validation
      • Optimization: Grid Search • Random Search • Bayesian Optimization
      Frameworks: TensorFlow • PyTorch • scikit-learn
      Deep Learning & Neural Networks
      • CNN: Conv2D → Pooling → Dense • Image classification, YOLO
      • RNN/LSTM: Sequential data • Time series • NLP
      • Transformer: Self-attention • BERT • GPT • ViT
      model = Sequential([ Conv2D(32, (3,3), activation='relu'), MaxPooling2D(2,2), Dense(10, activation='softmax') ])
      Training: Backpropagation • SGD • Adam • LRS • Transfer learning
      Blockchain & Web3 CNTT1186
      Core Concepts:
      • Distributed ledger
      • Consensus: PoW, PoS
      • Smart contracts
      Technologies:
      • Ethereum, Solidity
      • Web3.js, IPFS
      • DeFi, NFT, DAO
      Big Data & Emerging Tech
      • Big Data: Hadoop • Spark • Kafka • Data Lake
      • Cloud AI: AWS SageMaker • Azure ML • AutoML
      • Emerging: Quantum Computing • AR/VR • Edge AI • 6G
      5V: Volume • Velocity • Variety • Veracity • Value