473,395 Members | 1,386 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Is it posible to use only stdio.h library to find roundup value, and find all the

Is it posible to use only stdio.h library to find roundup value, and find all the factor of a number


I am wondering how roundup is work with using a function but not cmath library, and how to find all the factor of a number by onlt stdio.h too.
Oct 22 '10 #1
2 1610
I think you are asking if stdio.h header file has any mathematical functions.Check the link bellow..

http://www.cplusplus.com/reference/clibrary/cstdio/
Oct 23 '10 #2
donbock
2,426 Expert 2GB
Are you asking about rounding a floating point value? There are several rounding strategies:
  • Round towards zero (truncation). For example, 35.8 rounds to 35, -40.7 rounds to -40.
  • Round to nearest. For example, 35.3 rounds to 35, 35.6 rounds to 36. Not clear what 35.5 rounds to.
  • Round towards infinity. For example, 35.2 rounds to 36, -40.9 rounds to -40.
  • Round towards negative infinity. For example, 35.8 rounds to 35, -40.1 rounds to -41.
  • Round to larger magnitude. For example, 35.2 rounds to 36, -40.2 rounds to -41.
  • Some other strategy I haven't listed.
Which of these best suits your needs?

Notice that the C Standard assures you that "round towards zero" (truncation) is used automatically if you cast a floating point value into an integral variable.
Oct 23 '10 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Jean Stax | last post by:
Hi ! I created a sample library project. In my second project I reference this library and make the following call, which returns "undefined value": Type myType =...
0
by: Ian Lazarus | last post by:
Hello, A call to std::basic_string<wchar_t>::find(...) from within a class library is not working as expected. The value passed to find is 0x61, but the value it receives is 0xE961. What's...
4
by: Jon | last post by:
hi, I would like to know is there a function in datacolumn that can get the largest value in a column in a dataset? otherwise what is the best way to do it? thanks, jon
2
by: Ros | last post by:
Peeps, I need help with trying to find a value in array of arrays. Public Module myModule Private Site_Access() As Array Property Set_SA() Get Return Site_Access End Get
0
by: gurusshetty | last post by:
Hi Is there any way to find previous value of data column or text in c#. Regards, Guru
1
by: umeshdchaudhari | last post by:
fist I filled value of drow down and GridView control. Now we find the databound of grid view control as per drow down value at time binding. ? How we find the value of control time of binding in...
3
by: krishnaneeraja | last post by:
Hi, im developing one web application using asp.net,c#.net.In that i want to find ASCII value of first character in a string.plz help me. thanks.
2
by: donpro | last post by:
Hi, Does anyone know how to use DOM to find the value of a selected radio both (or if none were selected)? My web page displays a set of radio buttons - the number is dynamic so could be one...
1
by: ritaggalande | last post by:
how to find ascii value of charater using c#.net
1
JustRun
by: JustRun | last post by:
Hi, Well, I have a DataGridView binded to a TableAdapter and there is an extra empty column named "clmImg" to put an image or color in it. I want to do the following : search through the...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
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,...
0
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...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
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...
0
tracyyun
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...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.