Skip to content

Instantly share code, notes, and snippets.

//In this challenge, write a program that takes in three arguments, a start temperature (in Celsius), an end temperature (in Celsius) and a step size.
//Print out a table that goes from the start temperature to the end temperature, in steps of the step size; you do not actually need to print the final end temperature if the step size does not exactly match.
//You should perform input validation: do not accept start temperatures less than a lower limit (which your code should specify as a constant) or higher than an upper limit (which your code should also specify).
//You should not allow a step size greater than the difference in temperatures. (This exercise was based on a problem from C Programming Language).
//Ask user for start temp (in celsius)
//Ask user for end temp (in celsius)
//ask user for step size
@chrisscherer
chrisscherer / GsonRequest.java
Last active February 9, 2017 20:40 — forked from ficusk/GsonRequest.java
A modified Volley adapter for JSON requests that will be parsed into Java objects by Gson and allows for all REST methods
import com.android.volley.AuthFailureError;
import com.android.volley.NetworkResponse;
import com.android.volley.ParseError;
import com.android.volley.Request;
import com.android.volley.Response;
import com.android.volley.Response.ErrorListener;
import com.android.volley.Response.Listener;
import com.android.volley.toolbox.HttpHeaderParser;
import com.google.gson.Gson;
import com.google.gson.JsonSyntaxException;