The quickest way to get started with the basics is to get an API key from either OpenAI or Azure OpenAI and to run one of the Java console applications/scripts below ...
If you want to time a segment of code you may do the following. Instantiating Timer is equivalent to Timer.start(). Timer t = new Timer(); String val = searchForStuff(); System.out.println("It took " ...