Students staged a walkout yesterday in protest at a university's first ever 'consent classes' aimed at preventing rape and sexual harassment on campus.

Every first-year was expected to go to the sessions at York University, although officials said that attendance had not been compulsory.

Student union leaders said the 'gender neutral' lessons were necessary to protect freshers' 'wellbeing, physically and mentally'. The aim of the classes was to make students aware of the definition of rape and how to avoid raping someone or becoming a rape victim. But others on campus branded the ten-minute classes 'patronising'.

One consent class saw a quarter of freshers walk out in disgust and handfuls walked out of several of the others.

Campus activist Ben Froughi, 23, a third-year accounting student, stood outside some of the sessions handing out fliers and encouraging students to boycott the talks if they disagreed with them.

Every first-year student was expected to go to the 'sex consent' sessions at York University

'Consent talks are patronising,' he said. 'If students really need lessons in how to say yes or no then they should not be at university.

'There is no correct way to negotiate getting someone into bed with you. In suggesting that there is, consent talks encourage women to interpret sexual experiences that have not been preceded by a lengthy, formal and sober contractual discussion as rape.

'Consent talks propagate the backward message that all women are potential victims and all men potential rapists.'

The talks at the elite Russell Group university were led by students' union women's officers Mia Chaudhuri-Julyan and Lucy Robinson.

They claimed Mr Froughi's behaviour led to a compromising of students' safety, and told student newspaper Nouse: 'The talks were gender neutral, short and solution based. They were accessible to all and invited questions and discussion.'

It follows a nationwide initiative by the National Union of Students to 'combat rape culture' through consent classes.

In NUS guidelines, class leaders are instructed to tell freshers the legal definition of rape and sexual assault and discuss the dangers of 'victim-blaming' and 'slut shaming'.

Yesterday's walkout came after Warwick University student George Lawlor was bullied online and branded a 'rapist' and 'misogynist' by activists last year after he dared to question consent workshops.

In a blog, he argued that the overwhelming majority of people 'don't have to be taught to not be a rapist' – and that men inclined to commit the crime would be unlikely to attend such a workshop.

Student unions across the country have been criticised for their 'safe space' policies. These are aimed at helping women and minorities feel safe on campuses, but many believe they have gone too far after activists campaigned to ban a range of mainstream speakers over fears their outspoken views could cause offence.

A York University spokesman said: 'The university supports the students' union's voluntary gender-neutral sexual consent briefings for new students as an aspect of the health and personal safety induction we give at the start of the academic year. The aim is to help raise awareness and to help reduce the likelihood of harassment.