/csci6212_p3

Project 3 in CSCI 6212-12 (Fall 2023 @ The George Washington University)

Primary LanguagePython

CSCI 6212_12 - Project 3

Project 3 in CSCI 6212-12 (Fall 2023 @ The George Washington University)

<Team 1> Members

  • Karan Patal
  • Oscar(Jiaye) Fang
  • Keuntae Kim
  • Edward Yeboah

Problem

  • Problem #0
    • Teleportation in Astro haunted galaxies
      • You have a teleporter that can take you from galaxy i to galaxy j. Cost to teleport is given by c(i,j), which can be arbitrary. Some galaxies are “astro-haunted” – this is specified by a(i) which can be 0 or 1 (1 means that that galaxy is “astro-haunted”). Give a polynomial time algorithm that minimizes the cost of going from galaxy 1 to galaxy n, such that you pass through no more than k astro-haunted galaxies. (You can assume that galaxies 1 and n are not astro-haunted.)

How to Run (Examples)

teleportation.py

python teleportation.py 100

OR

python3 teleportation.py 100

  • The number is the value of n (Number of Galaxies)

Teleportation.java

javac Teleportation.java
java Teleportation 100

  • The number is the value of n (Number of Galaxies)