C# da typelar

jamoliddin010

Jamoliddin

Posted on August 4, 2022

C# da typelar

C# da xotiraga 2 xil usulda saqlanadi Reference type alohida va value typelar alohida saqlanadi
*Reference type *

string
Arrays 
class
interface
delegate
Enter fullscreen mode Exit fullscreen mode

Value type

bool
byte
char
decimal
double
enum
float
int
long
sbyte
short
struct
uint
ulong
ushort
Enter fullscreen mode Exit fullscreen mode

Farqi

Reference type lar heap xotiraga value type lar stack xotiradan joy egallaydi. Reference type lar ishlashi pointerga o'xshaydi. Masalan

 string a , b ; a = hello ;
b = a;
Enter fullscreen mode Exit fullscreen mode

bunda a ga heap xotiradan joy ajratadi b ni a ga o'zlashtirganimizda a ga alohida joy ajratmasdan xuddi pointer kabi murojat qiladi.Value type larda esa aksincha bo'ladi

💖 💪 🙅 🚩
jamoliddin010
Jamoliddin

Posted on August 4, 2022

Join Our Newsletter. No Spam, Only the good stuff.

Sign up to receive the latest update from our blog.

Related

What was your win this week?
weeklyretro What was your win this week?

November 29, 2024

Where GitOps Meets ClickOps
devops Where GitOps Meets ClickOps

November 29, 2024