diff options
-rw-r--r-- | src/esieequest/Room.java | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/esieequest/Room.java b/src/esieequest/Room.java index 0ba71d9..4626490 100644 --- a/src/esieequest/Room.java +++ b/src/esieequest/Room.java | |||
@@ -1,6 +1,7 @@ | |||
1 | package esieequest; | 1 | package esieequest; |
2 | 2 | ||
3 | import java.util.HashMap; | 3 | import java.util.HashMap; |
4 | import java.util.Iterator; | ||
4 | import java.util.Set; | 5 | import java.util.Set; |
5 | 6 | ||
6 | /** | 7 | /** |
@@ -85,9 +86,9 @@ public class Room { | |||
85 | */ | 86 | */ |
86 | public String getExitString() { | 87 | public String getExitString() { |
87 | String vExitString = "Available exits:"; | 88 | String vExitString = "Available exits:"; |
88 | Set<String> keys = this.aExits.keySet(); | 89 | Set<String> vKeys = this.aExits.keySet(); |
89 | for (String exit : keys) { | 90 | for (Iterator<String> vIter = vKeys.iterator(); vIter.hasNext();) { |
90 | vExitString += " " + exit; | 91 | vExitString += " " + vIter.next(); |
91 | } | 92 | } |
92 | vExitString += "."; | 93 | vExitString += "."; |
93 | return vExitString; | 94 | return vExitString; |