I have dynamic list have multi value as dynamic number needs to convert to string like below example. when I test it in dartpad it will work only if I have one entry in (listN) but when I have multi entry in (listN) will show me null
please advice
void main() {
Map <dynamic,String> month= {
1: 'January',
1: 'February',
3: 'March',
4: 'April',
5: 'May',
6: 'June',
7: 'July',
8: 'August',
9: 'September',
10: 'October',
11: 'November',
12: 'December',
};
List<dynamic> listN = [1,3,4];
print (month[listN]);
}
I expect show me the results as (January March April)
New contributor
CallMe is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.