Can i do reverse mapping in solidity language.
case 1 :
mapping(address=>uint256) ----- mapping
mapping(uint256=>address) ------reverse mapping
can we perform case 2 in solidity successfully?
mapping(uint256=>address) is valid.
Mapping types are declared as mapping(_KeyType => _ValueType). Here _KeyType can be almost any type except for a mapping, a dynamically sized array, a contract, an enum and a struct. _ValueType can actually be any type, including mappings.
But, if the value of the first mapping is a mapping or struct, then a reverse mapping would not be possible.
See the source (Solidity docs) for more information.