TGTGInsighttelegram intelligenceLIVE / telegram public index
← Python Заметки

TGINSIGHT SIMILAR POSTS

Најди сличен содржај

Изворен канал @pythonotes · Post #273 · 26 јул.

В стандартном модуле random есть две очень похожие функции random.randint() random.randrange() Обе возвращают случайное значение из указанного диапазона >>> random.randint(10, 20) 12 >>> random.randrange(10, 20) 17 В чем же отличие? Дело в том что у randrange() есть третий параметр step. randint() действительно возвращает случайное число из указанного диапазона. randrange() на первый взгляд делает тоже самое если передать также два параметра. Но есть указать еще и step то наш диапазон усложняется, то есть в него попадёт не полный ряд значений. Например, я хочу получить случайное значение из диапазона но только чётное число. Тогда достаточно сделать так: >>> randrange(10, 20, 2) 16 Таким образом получается что randint это частный случай randrange без указания параметра step. Еще одно важное отличие в том, что randint() включает в диапазон второе значение а randrange() нет. То есть выражение randrange(10, 20) никогда не вернёт 20, а randint(10, 20) вернёт. #tricks#basic

Резултати

Пронајдени 7 слични објави

Пребарај: #bikes

当前筛选 #bikes清除筛选
Car News

@car_news · Post #1891 · 16.03.2026 г., 13:28

🇯🇵 Yamaha releases the world’s first production scooter with an airbag 🏍 The new Tricity 300 (2026) features a collision detection system that deploys an airbag from under the handlebar during an accident. 🤞 Tests show that using this system reduces life-threatening risk by more than 30 times. 💰 Sales are expected to start next quarter. The official price hasn’t been announced yet, but the current Tricity 300 version costs around $10,000. #bikes@Car_News

Hashtags

Car News

@car_news · Post #1650 · 08.11.2025 г., 14:45

🏍Brabus unveils motorcycle priced at €42,000 📰 German tuning house Brabus has presented the exclusive 1400 R Signature Edition bike, based on the KTM 1390 Super Duke R EVO. 🔎 The motorcycle features carbon bodywork, 17-inch Monoblock II EVO Platinum Edition wheels, leather seats with Dinamica microfiber, and special dashboard graphics. 🐎 The 1.35-liter V2 engine retains its 190 hp and 145 Nm output and is complemented by a Brabus exhaust system. The bike is equipped with WP-APEX semi-active suspension and Brembo brakes. #bikes#Brabus@Car_News

Car News

@car_news · Post #1591 · 17.10.2025 г., 12:40

📰Yamaha goes full cyberpunk 🏍 This is the MOTOROiD 2, a motorcycle from the future. 🔎 It features a self-balancing system that keeps the bike upright and prevents it from tipping over. The bike can recognize its owner’s face and respond to gestures. Instead of traditional handlebars, it has integrated grips built into the body and supports autonomous control. #Yamaha#bikes@Car_News

Bali News

@balinews · Post #346 · 11.03.2025 г., 12:00

🛵Bali governor wants to ban tourists from driving bikes...again 😠 Bali Governor Wayan Koster has decided to revisit the topic of tourists driving motorcycles. He complained that foreigners are recklessly riding motorcycles without clothes and without helmets. 📰 The governor plans to introduce a regional PERDA regulation banning tourists from driving motorcycles. The measure is proposed in response to frequent traffic violations by commuters and is aimed at improving safety and order on the roads. 🤔Such initiatives have arisen before, but did not find support from the authorities and were not implemented. It is still unknown whether this decree will pass now, as the Minister of Tourism in Indonesia has changed since last time. @BaliNews #transport#bikes#rules#tourism