Passengers travelling without a ticket

I travelled to Dodoma in the standard gauge railway (SGR) last month.  During the on board ticket examination, some passengers were found to have no tickets and others had tickets destined for areas the train had already left the station. I did not care to see what happened to them since I was very tired and needed to take a nap before I arrived at my destination. Nonetheless, I cannot help but wonder what the law says about this. Please enlighten me.
EM, Dodoma

According to section 46(1) and (2) of the Railways Act, 2017 (Act No. 10 of 2017) (the Act) it is prohibited to travel in a passenger train unless in possession of a valid ticket. Any person found on a passenger train without a valid ticket will be required to pay to the Corporation on top of actual fare to the penalty of 100% of the fare. According to section 49(1)(b) of the Act, any person who travels in a passenger train beyond the place authorised by his ticket will be required to pay to the Corporation on top of the actual fare a penalty of 100% of the fare and if on demand by an authorised officer, any person refuses to pay the fare and excess charge for which he is liable under this section, an authorised officer or police officer may, if there is reasonable ground to believe that there would be difficulty or delay in bringing that person before the Court by any other means, arrest and detain that person without a warrant and bring him, as soon as practicable, before a Court having jurisdiction to deal with him in accordance with the provisions of the Act.

When a passenger refuses to pay the extra charge it is considered an offence. According to section 88(a), (b) and (d) of the Act, any person who travels on a train without a valid ticket to avoid payment of any fare for which he is liable; or having a valid ticket for a certain distance, knowingly or unknowingly travels on a train beyond that distance to avoid payment of the fare for the additional distance; and refuses to pay the fare and excess charge which, on demand, he is liable to pay under the Act commits an offence, and will be liable on conviction to a fine of not less than TZS 100,000 but not exceeding TZS 500,000 or to imprisonment for a term of not less than 3 months but not exceeding 6 months, or to both such fine and imprisonment. It is good for you to now know this and advise fellow citizens to comply with the law.