Java tutorial
//package com.java2s; import java.util.Calendar; import java.util.GregorianCalendar; public class Main { public static boolean isFridayOrSaturday() { Calendar date = new GregorianCalendar(); return date.get(Calendar.DAY_OF_WEEK) == Calendar.FRIDAY || date.get(Calendar.DAY_OF_WEEK) == Calendar.SATURDAY; } }