Hello there,
How to drive more website traffic?
Answer: Advertise
It might be a LAN or Host network. I'm not sure about your question, but your answer might reside in your notes for this class.
Answer:
see explaination
Explanation:
Please find the screenprint and the VBA code. As shown in the screenprint, range B1 is used to enter the number of petals. If you want to use a different cell for petals input, then change the code accordingly.
Also, the VBA code is placed in the Sheet1 module. No new modules are inserted.
Screenprint: see attachment for screenshot
VBA Code:
Private Sub CommandButton1_Click()
Call daisyDecisions
End Sub
Private Sub daisyDecisions()
Dim remainder As Integer
Dim noOfPetals As Integer
noOfPetals = Sheet1.Range("B1").Value
remainder = noOfPetals Mod 2
If remainder <> 0 Then
MsgBox "He/She loves you!!!"
Else
MsgBox "He/She loves you not!!!"
End If
End Sub
Answer:
Following are the program in c#
using System; // namespace system
using System.Collections.Generic; // namespace collection
using System.Linq;
using System.Text;
namespace test // namespace
{
class Program1 // class
{
static void Main(string[] args) // Main function
{
double nMiles, nKm;
Console.Write("Enter Value In Miles : ");
nMiles =Convert.ToDouble(Console.ReadLine());
nKm = (nMiles / 0.62137);
Console.WriteLine("Output:");
Console.WriteLine("Value In Miles :" + nMiles);
Console.WriteLine("Value In KM :" + nKm);
Console.Read();
}
}
}
Output:
Case A-
Enter Value In Miles : 10
Value In Miles : 10
Value In KM : 16.09347
Case B-
Enter Values In Miles : 3.25
Value In Miles : 3.25
Value In KM : 5.230378
Explanation:
Here we take a input value in "nMiles" variable and converted into a Km. that will stored in "nkm" variable . To convert miles into km we use calculative formula Km=(miles/0.62137). This formula convert the entered value into km and finally print the value of miles and km miles variable.