def count_rows_greater(curs, table_name, x_gte=5, y_gte=5):
    """Queries to find number of rows in table in database where x is greater
    than or equal to x_gte and y is greater than or equal to y_gte.

    Args:
        curs (sqlite3.Cursor): cursor to database
        table_name (str): name of table to query
        x_gte (int): minimum value of x for query (default 5)
        y_gte (int): minimum value of y for query (default 5)
    Returns:
        (int): number of rows with x greater than or equal to x_gte and y
            greater than or equal to y_gte"""
    assert x_gte is not None and y_gte is not None
    where_str = ""
    val = None
    if x_gte is None:
        where_str = "WHERE y >= ?"
        val = (y_gte)
    elif y_gte is None:
        where_str = "WHERE x >= ?"
        val = (x_gte)
    else:
        where_str = "WHERE x >= ? AND y >= ?"
        val = (x_gte, y_gte)
    return curs.execute("""SELECT COUNT(*)
    FROM {}
    {};""".format(table_name, where_str), val).fetchone()[0]