473,749 Members | 2,597 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Just a tiny question.

64 New Member
Hey guys, thank for the help before and maybe you can help me a little more :-).

Here is the question they are asking...

"Write a statement that reads a floating point (real) value from standard input into temperature. Assume that temperature. has already been declared as an double variable."

I been trying to figure out what it means. I tried scanf, but just get some error message. Any help would be great. Thanks.

Oh btw this isn't a homework question. I been using this site to help me learn C++ the site is turingscraft.
Jan 23 '07
12 9836
johny10151981
1,059 Top Contributor
what compiler are you using??

Don't say you are compiling on that site. its not a very good answer.

follow the link
to get a detail of scanf string format.

%lf is used for double
%f is for float
Dec 28 '11 #11
nareddyt
2 New Member
@johny10151981
I'm using Pelles C.

You would use %lf, because it the prompt says "temperatur e" has been declared as a double...
Dec 28 '11 #12
Heather34
1 New Member
scanf ("%lf", &temperature );
Sep 14 '16 #13

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

Similar topics

2
1696
by: Sven Kobow | last post by:
Hello, I'm not yet a python programmer but a python user. I faced a problem with tiny fonts in a wxPython app on a GNU/Debian system. Under Gentoo Linux the fonts are displayed in a normal readable size. Only on that Debian system fonts in the whole app are rather tiny. I spend quite a long time googling for a solution and found several hints on font problem issues in wxPython but none fitted to that mentioned above. Does anybody has a...
5
2212
by: Mel | last post by:
i would like to place a tiny image on the top-left corner of all screens and on clicking the image to to http://www.somewhere.com url can you please help ?
5
6510
by: drj0nson | last post by:
Without getting too mathematical : how do you print/handle big numbers? for ( int i = 1 ; i < 10 ; i ++) cout << (123456789 << i) << endl; 246913578 493827156 987654312 1975308624 -344350048
2
1767
by: Pieter Linden | last post by:
The answer to this one is probably "test it yourself and find out!", but I'll ask anyway. Pursuant to my previous question - sending separate recordsets to Word using the CreateTableFromRecordset code from ADH2000... I will be opening like 8 recordsets {one for each building, and there are 8). Would I be better off or is there anything to be gained by opening one recordset of the query with _all_ the records in it, filtering that, and...
7
5892
by: Werner Nussbaumer | last post by:
Hello I am searching for a version of the Tiny C compiler for Windows 32. I downloaded a version from http://fabrice.bellard.free.fr/tcc/ but the make command displayed error messages: P:\DEVELOP\c2\TCC-09~1.20>make MAKE Version 5.2 Copyright (c) 1987, 1998 Inprise Corp. Error makefile 5: Command syntax error Error makefile 13: Command syntax error
2
1960
by: Justin Naidl | last post by:
A group of friends and I are doing a RPG (role-playing game) maker for a school project. It occured to us, however, that if you want the user to be able to have almost complete control over the contents of his/her game, that you would end up with a tiny executable and a huge datafile. We wanted to keep clear of this as disk accesses take a lot of time to do and there would be a huge load of them to do this part. We could very easily...
5
4078
by: soeren | last post by:
Hello, two days ago I stumbled across a very strange problem that came up when we were printing tiny double numbers as strings and trying to read them on another place. This is part of an object serialisation framework that cannot be done in binary format currently, so please no comments about this ,-)) It took quite some time to shrink down the problem but it looks like that C++ does not behave well in regards to very tiny numbers.
2
1628
by: Martijn Mulder | last post by:
I want to implement a tiny window in my application, one that you typically invoke via the menu-option Window -Toolbar. It must be floating, not restricted to the client area of the controlling form. It has a tiny close-button on the right-hand corner. How do I implement this?
14
5615
by: rtk | last post by:
I'm looking for information on building a tiny/small/minimalist/ vanilla python interpreter. One that implements the core language and a few of the key modules but isn't tied to any specific operating system. I guess I'm asking for the smallest subset of the standard Python source code files that is necessary to get a working interpreter using a plain C compiler. Is this even possible? If so, has someone done it already? I've
0
8997
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, 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 usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9568
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9389
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9256
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 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 choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8257
agi2029
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 launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6079
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4709
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 the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
2
2794
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2218
bsmnconsultancy
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 effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.