Попробуй это:
<div className={styles.city}>
{houses.map(function (house){
const numOfFloors = parseInt(house.name);
const floors = [];
for (let i = 0; i < numOfFloors; i++) {
floors.push(<Floor key={i}/>);
}
return (
<House key={house.name}>
{floors}
</House>
);
})}
</div>