Substract 82.30 - 72.50 (Type Degree)
Answer require : 09.40 (Type Degree)
Multiply : 09 x 4 Second
Ans : 36 Min
Multiply : 40 x 4 Second
Ans : 160 Second
convert : 36 Min.160 Sec
as 36 Min. + 2 Min 40 Second
Final Ans require : 38 Min. 40 Sec
3 2221 Luuk 1,047
Recognized Expert Top Contributor
Can you explain in words what you are trying to do?
I am alrady loast at your second sentence:
"Answer require : 09.40 (Type Degree)"
You need a 'final value in min.sec', but do not specify what 82.30 and 72.50 is.
What correlation has 'Degree' with min.sec. ?
Conversion from Integer type to TimeSpan Type - Dim imin As Integer = 82
-
Dim isec As Integer = 30
-
Dim ts1 As New TimeSpan(0, imin, isec)
Time calculation (adjustment) - Dim ts1 As New TimeSpan(0, 82, 30)
-
Dim ts2 As New TimeSpan(0, 72, 50)
-
Dim ts3 As TimeSpan = ts1 - ts2
Convert - Dim ts3 As New TimeSpan(0, 36, 160)
Time calculation(mul tiplication) - Dim L As Long = ts1.Ticks * 7
To Striing - Dim min As String = Mid(ts3.ToString,4,2)
-
Dim sec As String = Mid(ts3.ToString,7,2)
You can handle your degrees as timespans: - Dim StartValue As TimeSpan = New TimeSpan(0, 72, 50)
-
Dim StopValue As TimeSpan = New TimeSpan(0, 82, 30)
-
-
Dim Factor As Double = 4
-
Dim Final As TimeSpan = TimeSpan.FromSeconds(StopValue.Subtract(StartValue).TotalSeconds * Factor)
-
-
Console.WriteLine(Final.ToString("mm':'ss"))
-
-
' -> 38:40
Sign in to post your reply or Sign up for a free account.
Similar topics |
by: Jonas |
last post by:
Dear members,
How can I use a function return value in a regexpr?
$tmp=~s/mysearch/myfunction($1)/;
sub myfunction {
return $v;
}
|
by: Hitesh Patel |
last post by:
hi friends,
read following code and my problem.
class B
{
private:
public:
void fun1(void)
{
|
by: Tropos |
last post by:
Query: Will a MutexGuard object release before a function return value
is copied?
Consider the C++ code:
class MutexGuard //A familiar sort of class for making mutexes
exception-safe
{
. . .
~MutexGuard(); //releases the mutex when the stack pops
|
by: Michael Klatt |
last post by:
class Foo
{
public :
explicit Foo(int i) : m_int(i) {}
private :
int m_int;
};
Foo f(int i)
|
by: Michel Rouzic |
last post by:
I'm sure that it's a dumb problem where i surely did something dumb,
but, I got a problem, I got a variable that we'll call var1. in the
main() function, this variable var1 (of type unsigned) of a value of
lets say 1000. now i got a function that we'll call func1, declared by
void func1(unsigned var1) and called by func1(var1);. in this...
| |
by: startsmart |
last post by:
Hi
This is first time to write and alse it is first time to show this site
my problem is i need to pass value from any input type like text for example
to hidden field
I tried to make a function but it does not work
function hdate(){
|
by: pradeep |
last post by:
Hello friends ~
We know that a C function will return a 32-bit value from a function
in %eax and a 64-bit value in %edx:%eax. But what about larger return
types, for example large structs? The only other spare register is
%ecx because %ebx needs to be preserved, but that only brings the
%possible total up to 96 bits. What happens after...
|
by: kurt.krueckeberg |
last post by:
Can someone explain why this line
$bool = isset($_POST) && !empty(trim($_POST));
causes the error message "Can't use function return value in write
context". trim() returns a string. I test if it is empty. So what is
wrong with that?
|
by: Rajib |
last post by:
Not that this serves any real purpose, but gcc allows me to do some hack
like this:
class hide_A {
public:
class A {
public:
virtual int final() { return 42; }
};
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language...
| |
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...
| |