Question about Microsoft Computers & Internet

The out put should be totally in integers with out and exponential value

Ad

If it's an int type it's already integer without exponential for examle:

void main()

{

int num=5;

num/=2;

clrscr();

printf("%d",num);

}

so the out put is 2 and no 2.5 or:

for(int i=0; i<num; i++)

so 'i' is the integer part of num.

Rate me please, thanks.

Posted on Jul 11, 2009

Ad

Hi there,

Save hours of searching online or wasting money on unnecessary repairs by talking to a 6YA Expert who can help you resolve this issue over the phone in a minute or two.

Best thing about this new service is that you are never placed on hold and get to talk to real repairmen in the US.

Here's a link to this great service

Good luck!

Posted on Jan 02, 2017

Ad

If they're integer values (assuming they're already in variables named A and B), you could use

int C=A; if (B>A) C=B; printf ("Largest is %i\n", C);

int C=A; if (B>A) C=B; printf ("Largest is %i\n", C);

Jun 01, 2014 | Borland Turbo C++ Suite 1.0...

Use the value that will be printed by the keyboar.

After you enter the value.

You have to cast the type you have used as integer or float into string or character type.

So here the type casting of the datatype will be used.

After you enter the value.

You have to cast the type you have used as integer or float into string or character type.

So here the type casting of the datatype will be used.

Oct 10, 2011 | Borland Turbo C++ 4.5 Full Version for PC

> what is computer pro gaming?

> what is computer programming?

The latter is the writing of instructions that a computer can follow, to solve a problem,

e.g.,

set the variable 'X' to the value '3';

set the variable 'Y' to the value '7';

calculate the value of X divided by Y, and store into 'Z';

display the value of 'Z', to 7 decimal-places;

stop running this program.

> what is computer programming?

The latter is the writing of instructions that a computer can follow, to solve a problem,

e.g.,

set the variable 'X' to the value '3';

set the variable 'Y' to the value '7';

calculate the value of X divided by Y, and store into 'Z';

display the value of 'Z', to 7 decimal-places;

stop running this program.

Jun 15, 2011 | Computers & Internet

If you want to get the ASCII value of a character, or just convert it into an int (say for writing to an OutputStream), you need to cast from a char to an int.

What's casting? Casting is when we explicitly convert from one primitve data type, or a class, to another. Here's a brief example.

public class char_to_int
{
public static void main(String args[])
{
char myChar = 'a';
int i = (int) myChar; // cast from a char to an int
System.out.println ("ASCII value - " + i);
}
}

In this example, we have a character ('a'), and we cast it to an integer. Printing this integer out will give us the ASCII value of 'a'.

Nov 04, 2010 | Answer Racing Ion Motorcycle Jersey 2010

Hi,

The following information on "Hierarchy of Operations" was taken from Pages 45-46 of the "Microsoft QuickBasic 4.0: Basic Language Reference" manual for Versions 4.00 and 4.00b. This information also applies to the following products:

For more information on the "Hierarchy of Operations," consult the Basic language reference manual for your version of Basic. Please post your feedback and Vote if the problem resolved as per your satisfaction.

The following information on "Hierarchy of Operations" was taken from Pages 45-46 of the "Microsoft QuickBasic 4.0: Basic Language Reference" manual for Versions 4.00 and 4.00b. This information also applies to the following products:

- Microsoft GW-Basic Versions 3.20, 3.22, and 3.23
- QuickBasic Versions 1.00, 1.01, 1.02, 2.00, 2.01, 3.00, 4.00, 4.00b, and 4.50
- Microsoft Basic Compiler Versions 5.35, 5.36, 6.00, and 6.00b
- Microsoft Basic PDS Version 7.00.

- Arithmetic operations

- Exponential (^)
- Negation (-)
- Multiplication and division (*, /)
- Integer division (\)
- Modula arithmetic (MOD)
- Addition and subtraction (+, -)

- Relational operations (=, >, <, <>, <=, >=)
- Logical operations

- NOT
- AND
- OR
- XOR
- EQV
- IMP

For more information on the "Hierarchy of Operations," consult the Basic language reference manual for your version of Basic. Please post your feedback and Vote if the problem resolved as per your satisfaction.

Jul 13, 2010 | Microsoft Windows XP Professional

This code takes two arguments, a string constructor from the Java language and an integer. Its purpose is to parse (meaning de-construct or disassemble into component parts) one data type into another.

Here is an example of a Java program to specify and print out the dimensions of a rectangle, taken from the page http://www.roseindia.net/java/beginners/entervaluesfromkeyboard.shtml:

length = x;

breadth = y;

}

}

}

Rectangle rectangle =

rectangle.show(a, b);

System.out.println(" you have entered these values : " + a + " and " + b);

System.out.println(" area of a rectange is : " + area);

}

}

Apr 09, 2009 | Sun Java Programming Language (cdj-275)

<!--StartFragment-->

Function InsertionSort(ByVal TempArray As Variant) As Variant

' Written By Louis Sutherland

' 1/25/99

' will be the sorted arrary when finishe

' d

Dim SortedList As Variant

Dim x, y As Integer

Dim NumSorted As Integer

'This Set up SortedList as an Array

SortedList = TempArray

'This zeroizes the new array

For x = 1 To UBound(SortedList)

SortedList(x) = 0

Next x

'sets the Total num counted to 1

NumSorted = 1

' Processes first element

SortedList(1) = TempArray(1)

For x = 2 To 5000

' insertion loop

For y = NumSorted To 1 Step -1

' if current value is <= then insert in

' next place

If TempArray(x) >= SortedList(y) Then

SortedList(y + 1) = TempArray(x)

'This Breaks the loop

y = 1

Exit For

Else

If y = 1 Then

SortedList(y + 1) = SortedList(y)

SortedList(y) = TempArray(x)

Exit For

Else

' save the value to the next spot

SortedList(y + 1) = SortedList(y)

End If

End If

Next y

'advance total num sorted

NumSorted = NumSorted + 1

Next x

InsertionSort = SortedList

End Function

Function InsertionSort(ByVal TempArray As Variant) As Variant

' Written By Louis Sutherland

' 1/25/99

' will be the sorted arrary when finishe

' d

Dim SortedList As Variant

Dim x, y As Integer

Dim NumSorted As Integer

'This Set up SortedList as an Array

SortedList = TempArray

'This zeroizes the new array

For x = 1 To UBound(SortedList)

SortedList(x) = 0

Next x

'sets the Total num counted to 1

NumSorted = 1

' Processes first element

SortedList(1) = TempArray(1)

For x = 2 To 5000

' insertion loop

For y = NumSorted To 1 Step -1

' if current value is <= then insert in

' next place

If TempArray(x) >= SortedList(y) Then

SortedList(y + 1) = TempArray(x)

'This Breaks the loop

y = 1

Exit For

Else

If y = 1 Then

SortedList(y + 1) = SortedList(y)

SortedList(y) = TempArray(x)

Exit For

Else

' save the value to the next spot

SortedList(y + 1) = SortedList(y)

End If

End If

Next y

'advance total num sorted

NumSorted = NumSorted + 1

Next x

InsertionSort = SortedList

End Function

Mar 17, 2009 | Microsoft Visual Basic 6.0 for PC

Write a program to prompt the user to input several lines of input. A line of inputs is terminated by '*'. For each readline of input the program should output:(use pointer notation for the array)
. The total # of words
. The lenght of the longest word in the line
At the end the program should output:
. The total number of words read in all lines of input
. The lenght of the longest word read in all lines of input

Jan 19, 2009 | Computers & Internet

1.In mathematics, the **factorial** of a non negitive integer *n*, denoted by *n*!, is the product of all positive integers less than or equal to *n*. For example,

and2. Algorithm to find factorial of 6

1. Start

2. Take two variables i and j.

3. Take a constent VALUE=6.

4. Put i=1,j=1.

5. If i is less than VALUE goto 6 else goto 7

6. j=j*i and goto step 5

7. Print j value.

8. Stop.

/* Program to find factorial of 6 */

#include <stdio.h>

#define VALUE 6

int i,j;

void main()

{

j=1;

for (i=1; i<=VALUE; i++)

j=j*i;

printf("The factorial of %d is %d\n",VALUE,j);

}

and2. Algorithm to find factorial of 6

1. Start

2. Take two variables i and j.

3. Take a constent VALUE=6.

4. Put i=1,j=1.

5. If i is less than VALUE goto 6 else goto 7

6. j=j*i and goto step 5

7. Print j value.

8. Stop.

/* Program to find factorial of 6 */

#include <stdio.h>

#define VALUE 6

int i,j;

void main()

{

j=1;

for (i=1; i<=VALUE; i++)

j=j*i;

printf("The factorial of %d is %d\n",VALUE,j);

}

Jan 19, 2009 | Computers & Internet

Q.2# Dim n, sum as Double

Dim i as Integer

n=100

sum=0

for i=1 to n

sum=sum+1/n

next i

Q.3# Dim sum as Double

sum=0

for i=1 to 99

if i%2 <> 0 then sum=sum+i end if

next i

Dim i as Integer

n=100

sum=0

for i=1 to n

sum=sum+1/n

next i

Q.3# Dim sum as Double

sum=0

for i=1 to 99

if i%2 <> 0 then sum=sum+i end if

next i

Sep 16, 2008 | Microsoft AccRepair DS2 2004 for Fr...

Jul 25, 2018 | Microsoft Computers & Internet

47 people viewed this question

Usually answered in minutes!

×