Ruby
xxxxxxxxxx
require 'set'
# Creation of new Set.
Vegetable = Set.new(["potato", "tomato","brinjal","onion"])
Vegetable.add("potato")
Vegetable.add("tomato")
Vegetable.add("Beetroot")
puts "Number of elements in set are #{Vegetable.size()}"
i = 1
Vegetable.each do |n|
puts "#{i} element is #{n}"
i = i + 1
end
Number of elements in set are 5 1 element is potato 2 element is tomato 3 element is brinjal 4 element is onion 5 element is Beetroot
Linux - anc-api-tools qanday o'rnatiladi
Linux - curvedns qanday o'rnatiladi
Python - Raqamning ijobiy, salbiy yoki 0 ekanligini tekshiring
Linux - zenmap qanday o'rnatiladi
C - Butun sondagi raqamlar sonini sanash
C++ - Kabisa yilini tekshiring
JavaScript - Satr ma'lum belgilar bilan boshlanishi va tugashini tekshiring
C++ - Raqam tub yoki oddiy emasligini tekshiring
C - Dinamik xotira ajratish yordamida eng katta raqamni toping
Linux - xbitmaps qanday o'rnatiladi
Kotlin - Raqamni n o‘nlik kasrgacha yaxlitlash
Linux - zstd qanday o'rnatiladi
Kotlin - Raqamni teskari aylantirish
Python - Excel (XLSX) fayllarini yozish
Java - Raqamni teskari aylantirish
C++ - Qism va qoldiqni toping
Java - Piramida va naqsh yarating
Linux - zfs-test qanday o'rnatiladi
We have been online since 2021 and 1 millions of people around the globe have visited our website since then
More visitors every month