will this work if y is a double with a value?int x = (int) y; June 21, 2017 mfadmin Java Programming Average Rating 0 out of 5 stars. 0 votes.You must log in to submit a review. will this work if y is a double with a value?int x = (int) y; YES!