What is represented by a verb can be used as the subject of a sentence by putting の after the plain form of the verb. The dictionary form and nai-form are particularly used. の changes the verb phrase into a noun-equivalent. Here, it is used with such words as たいへん(hard;time-consuming), きけん(dangerous), ざんねん(be a pity), and たのしい(enjoyable), which express the speaker's opinion or thoughts.
It's hard to prepare for classes every day.
It's regretful/it's too bad that I cannot go traveling.
The place where my older brother bought the book is Shibuya.