Ранее я уже упоминал о другой фишке из ˍˍfutureˍˍ , это оператор деления.
from __future__ import division
Суть проста. Раньше сложность типа данных результата поределялась типом самого сложного операнда.
Например:
int/int => int
int/float => float
В первом случае оба операнда int, значит и результат будет int. Во втором float более сложный тип, поэтому результат будет float.
Если нам требуется получить дробное значение при делении двух int то приходилось форсированно один из операндов конверировать в float.
12/float(5) => float
Но с новой "философией" это не требуется. В Python3 "floor division" заменили на "true division" а старый способ теперь работает через оператор "//".
>>> 3/2
1.5
>>> 3//2
1
То есть теперь деление int на int даёт float если результат не целое число.
В классах теперь доступны методы __floordiv__() и __truediv__() для определения поведения с этими операторами.
Данный переход описан в PEP238.
#pep#2to3#basic
#GMT/USDT analysis :
Following the breakout and subsequent retest of the 200 EMA, the price is now declining. It is anticipated that this downward momentum will persist, leading to a test of lower levels.
TF : 4H
Entry : $0.1586
Target : $0.1414
SL : $0.1670
#GMT/USDT analysis :
#GMT is in an uptrend on LTF. The price has broken and retested the 200 EMA. Currently, the price is bouncing back from the 200 EMA and is expected to continue its bullish momentum.
TF : 30min
Entry : $0.1132
Target : $0.1199
SL : $0.1089
#GMT overall trend is bearish, with a significant downtrend visible from the peak in late December.Price has been making lower highs and lower lows, indicating continuous selling pressure. 🔥👍✅
Further,As long as the price stays below $0.0847, the bearish trend remains strong.A potential relief bounce could occur, but confirmation is needed.Bulls need to reclaim resistance levels above $0.0847 to signal a possible trend reversal.👍🔥✅
#GMT is testing the major support zone and testing the Daily range low. Market is taking a correction before going up and we can see big moves in coming months.🔥✅
Further. GMT is looking good for investment in upcoming Alt Season.🔥✅😍👀✅🔥😳
#GMT will test the resistance zone and it has caused the liquidity on resistance zones .Market can see a breakout and bullish move soon,🔥✅
Further, market will take a bullish soon ahead as BTC.D will soon take a breakdown.🔥✅😍👀✅🔥😳
🔵#GMT price is rising in a Bullish channel on 6H Time frame,we expect it will have another bullish leg from the bottom of this pattern 👀
❄️@signals_bitcoin_crypto❄️
❄️@Shadow_support0o❄️