DEV Community

Nosirbek
Nosirbek

Posted on • Edited on

1 1

Linked List

  • Linked Lists - bu ketma-ketligi xotiradagi joylashuviga bog'liq bo'lmagan chiziqli ma'lumotlar to'plami.

  • Ro'yhatning har-bir elementi keyingi elementga ishora qiladi.

  • Ma'lumotlar tuzilmasi sifatida LinkeListni bir-biriga bog'langan tugunlar ko'rinishida tasavvur qilamiz.

  • Har bir tugun o'z qiymatini va keyingi element manzilini saqlaydi.

Image description
oxirgi element null

Image description

  • Arrayning - har-bir elementi xotirada ketma ket joylashgan bo'lishi kerak.
  • LinkedList - hohlagan bo'sh joyda joylashaveradi , har bir element o'zidan keyingi elementning manzilini saqalaydi.

Linked Listda biz 4- yoki 5- elementni o'qish uchun biz birinchi elementdat boshlab o'qib chiqishimiz kerak , chunki 4- elementning manzili 3- elementda , 3- niki esa 2- da va hokazo ...

Array Linked List
O'qish O(1) O(n)
Qo'shish O(n) O(1)
O'chirish O(n) O(1)

Arrays vs Linked Lists

Image description

Linked Lists turlari

Singly Linked Lists - Bir Tomonlama Ro'yhat

Image description
Circular Linked Lists - Aylana Ro'yxat

Image description
Doubly Linked Lists - Ikki Tomonlama Ro'yhat

Image description

C# da Linked List dan qanday foydalanish haqida keyingi postda yoritaman.

Speedy emails, satisfied customers

Postmark Image

Are delayed transactional emails costing you user satisfaction? Postmark delivers your emails almost instantly, keeping your customers happy and connected.

Sign up

Top comments (0)

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay