hey, guys! i've a java programming question for you. this one is fairly simple, but it comes in two parts. the first step:
Make a Java program, MapColorer, that outputs a four-coloring for any given planar map or a message indicating that it is impossible (i.e., that the given input does not constitute a planar map).
Your program will get all of its input from the args. args will specify the number of countries, presumed to be indexed from zero. The remaining args will be pairs of ints identifying pairs of adjacent countries.
Once that is done, the same program needs to be written but this time it must use standard input/output instead of the command line:
Make a second Java program, MapColorer2, that works exactly as above except that it gets all of its input from the standard input device. This will enable us to provide input via the keyboard; better yet, we can prepare input files and direct them to the program from the command line.
There are several ways to accomplish this; one method is described in Doing Standard I/O in Java (suggested link here, but it's not necessary http://my.cs.lmu.edu/~pdorin/stdio.in.Java.pdf ). The first line of the input file will specify the number of countries (a single int). Each remaining line will consist of a pair of ints which specify a pair of adjacent countries. As before, countries are indexed from zero.
also, this program does not have a gui interface, it's meant to use text output entirely in the terminal/command line