I want to use values from a dictionary in my UITableViewCells. Can I get those from a dictionary by using indexPath.row for the value and indexPath.section for the key?
you can get the keys array and get the key at indexPath.section
like this:
Array(yourDictionary.keys)[indexPath.section]
and you can get the value at indexPath.row
from the values array like this:
Array(yourDictionary.values)[indexPath.row]
Edit:
if you want to get the values of a specific section key you should write:
let key = Array(yourDictionary.keys)[indexPath.section]
let array = yourDictionary[key]
let value = array[indexPath.row]