public static Question movies_question(Connection conn) 
			throws ClassNotFoundException, SQLException, IOException{
		
		String[] q = new String[50];
		
		Statement stmt = conn.createStatement();
		ResultSet rst = stmt.executeQuery(" select count(*) from curr_cinema_movies where movies_used=1 ");
		rst.next();
		int num_choices=rst.getInt(1);
		
		int[] rnd = randomize(num_choices);
		int a=rnd[0],b=rnd[1],c=rnd[2],d=rnd[3];
		
		rst = stmt.executeQuery(" select * from curr_cinema_movies where movies_used=1 ");
		
		Integer id=0;
		Integer release_year;
		
		int j=1;
		for(int i=0; i<num_choices; i++){
			rst.next();
			if(i==a){
				release_year=rst.getInt(4);
				q[0]=rst.getString(2).replaceAll(" \\(film\\)", "");
				q[4]="release year: "+release_year.toString();
				id=rst.getInt(1);
			}
			if(i==b || i==c || i==d){
				q[j]=rst.getString(2).replaceAll(" \\(film\\)", "");
				j++;
			}
		}
		
		int i;
		
		rst = stmt.executeQuery(
				" select distinct t.name from curr_cinema_tags t, curr_cinema_movie_tag mt " +
				" where t.id=mt.tag_id and mt.movie_id="+id.toString()+" ");
		
		for(i=5; i<30 && rst.next(); i++){
			q[i] = "categories: " + rst.getString(1);
		}
		
		rst = stmt.executeQuery(
			" select distinct a.name from curr_cinema_actors a, curr_cinema_actor_movie am " +
			" where a.id=am.actor_id and am.movie_id="+id.toString()+" and movies_used=1 order by a.num_links desc ");
		
		for(; i<50 && rst.next(); i++){
			q[i] = "cast member: " + 
					rst.getString(1).replaceAll(" \\(actor\\)", "").replaceAll(" \\(actress\\)", "");
		}
		
		rst.close();
		stmt.close();
		
		return generate_question(q, i);
	}