JavaLabassign3
JavaLabassign3
Latha Sagar
RegNo: 12204652
Roll No: 42
Section: D2212
Codehs link:
https://codehs.com/sandbox/id/new-sandbox-program-1XHLVK
source code:
package assignment;
import java.util.*;
float hours;
float mins;
float secs;
void callDur()
int callStart=sc.nextInt();
System.out.println("enter ending time duration :");
int callEnd=sc.nextInt();
int totalTime=callEnd-callStart;
totaltime2=totalTime*60;
float startTime=sc.nextInt();
float endTime=sc.nextInt();
float callRate=totaltime2*9;
else
t.callDur();
h.hourCon();
Min m=new Min();
m.minCon();
s.secCon();
hours= totaltime2/60;
System.out.println("totalhour is :"+hours);
mins=totaltime2*60;
System.out.println("totalminsis :"+mins);
{
secs= (totaltime2*60*60);
System.out.println("totalsecs :"+secs);
Output: