Search Header Logo

Quiz on Stack Data Structure

Authored by ภัทราวุธ วิริยสกุลวัฒนา

English

University

Used 1+ times

Quiz on Stack Data Structure
AI

AI Actions

Add similar questions

Adjust reading levels

Convert to real-world scenario

Translate activity

More...

    Content View

    Student View

10 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

ข้อใดกล่าวถูกต้องเกี่ยวกับ Stack?

เป็นโครงสร้างแบบ FIFO

สามารถลบข้อมูลจากจุดใดก็ได้

เพิ่มข้อมูลจากด้านหน้าและลบจากด้านหลัง

ใช้หลักการ LIFO

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

ฟังก์ชัน pop() ทำหน้าที่ใด?

ตรวจสอบว่ากองว่างหรือไม่

ลบข้อมูลล่าสุดที่ถูกเพิ่มเข้าไป

เพิ่มข้อมูลเข้าไปใน Stack

ตรวจสอบข้อมูลทั้งหมดใน Stack

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

หาก Stack เต็ม การเรียกใช้ฟังก์ชัน push() จะเกิดอะไรขึ้น?

โปรแกรมหยุดทำงาน

ข้อมูลถูกเขียนทับ

เกิด Stack Overflow

ข้อมูลถูกลบออก

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

การใช้งานใดต่อไปนี้เหมาะกับ Stack?

ระบบจัดคิวธนาคาร

การค้นหาข้อมูลแบบ Binary

การย้อนกลับการทำงาน (Undo)

ระบบจัดตารางเวลารถโดยสาร

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

ในภาษา C++, โครงสร้าง Stack ถูกจัดเก็บอยู่ในไลบรารีใด?

<stdio.h>

<iostream>

<stack>

<stdlib.h>

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

คำสั่งใดใช้ตรวจสอบค่าว่างใน Stack?

stack.clear()

stack.size()

stack.pop()

stack.empty()

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

การเรียกใช้ peek() จะมีผลอย่างไร?

ลบค่าบนสุดของ Stack

อ่านค่าบนสุดโดยไม่ลบ

ตรวจสอบความยาว Stack

เคลียร์ Stack ทั้งหมด

Access all questions and much more by creating a free account

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

Already have an account?