Nifty: Some days you consider YYMDD format, some expiry you are giving YYMON format.
E.g. NSE:NIFTY24APR22400CE for 25Apr2024 expiry
E.g. NSE:NIFTY2450222400CE for 02May2024 expiry
BankNifty: you are considering YYMDD format for last expiry in April.
E.g. NSE:BANKNIFTY2443048200CE for 30Apr2024 expiry
It is all inconcistent
Attached is screenshots for both Nifty and Bank Nifty.
Please keep one format YYMMDD format for symbols.
Trading View's index looks like this NIFTY240425C22400 i.e. YYMMDD format
For FINNIFTY 24APR is considered for last expiry and BANKNIFTY240530 is considered.
Why is this consistently inconsistent?
Just follow one convention in coding or use Trading views Symbols if you like. Also 'YYMDD' is wrong format it should be YYMMDD other wise you will not address November and December month correctly See how beautiful Tradingview's symbols are NIFTY<YYDDMM><C/P><StrikePrice>