Program to find minimum number of lectures to attend to maintain 75 % | C # Program to find minimum number of lectures to attend to maintain 75 % attendance ; Method to compute minimum lecture ; Formula to compute ; Driver Code
using System ; class GFG { static int minimumLectures ( int m , int n ) { int ans = 0 ; if ( n < ( int ) Math . Ceiling ( 0.75 * m ) ) ans = ( int ) Math . Ceiling ( ( ( 0.75 * m ) - n ) / 0.25 ) ; else ans = 0 ; return ans ; } public static void Main ( ) { int M = 9 , N = 1 ; Console . WriteLine ( minimumLectures ( M , N ) ) ; } }