Skip to content

Instantly share code, notes, and snippets.

@RalXYZ
Created November 29, 2020 10:55
Show Gist options
  • Save RalXYZ/b11f056bfac2befa3dba485d4831c1f9 to your computer and use it in GitHub Desktop.
Save RalXYZ/b11f056bfac2befa3dba485d4831c1f9 to your computer and use it in GitHub Desktop.
import cyaron
f = open("input.txt", "w")
vertex = int(input("vertex num: "))
edge = int(input("edge num: "))
starting_point = int(input("starting vertex: "))
graph = cyaron.Graph.graph(vertex, edge, weight_limit=(1, 100), self_loop=False, repeated_edges=False)
f.write(str(vertex) + " " + str(edge) + " " + str(starting_point) + "\n")
f.write(str(graph))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment