Which sentence is more formal?
The first part of the trail is a piece of cake, but the last three miles are physically demanding. The first part of the trail is quite flat, but the last three miles are physically demanding.
Formal writing is used for essays, business letters, and reports. The following types of informal language should be avoided in formal writing:
Type | Examples
slang | cool, awesome
idioms | knock your socks off
conversational language | gonna, kinda, yeah
abbreviated language | ASAP, FYI
overly simple or imprecise language | he got some stuff at the store
contractions | can't, won't
Contractions are not as informal as the other types, but they should be used sparingly in formal writing.
Compare the following sentences. The first is informal. The second is formal.
Informal: Yeah, ostriches can't fly, but they're awesome runners.
Formal: Though ostriches are flightless, they are remarkably adept runners.

The second sentence is less formal. You can tell because it uses an idiom (piece of cake).
The first sentence uses formal language in place of the idiom, so it is more formal overall.