Or login with:
| doubletemperature( | double | number | |
| units | from_unit | ||
| units | to_unit | ) |
#include <iostream> #include <codecogs/units/convert/temperature.h> using namespace Units::Convert; int main() { std::cout << "temperature(37,unit_C, unit_K)=" << temperature(37,unit_C, unit_K); return 0; }Output:
temperature(37,unit_C, unit_K)= 98.6
| number | the value in from_unit 's to convert |
| from_unit | an enumerated value of the initial temperature type |
| to_unit | an emuerated value of the output temperature type |
Source code is available when you buy a Commercial licence.
Not a member, then Register with CodeCogs. Already a Member, then Login.
| Unit names | Alternate names / spellings | Abbreviation | Enumeration Code | Conversion Rate (relative to first unit) |
| Temperature | ||||
| Celsius | deg C | C | unit_C | 1 |
| Fahrenheit | deg F | F | unit_F | 1.8 |
| Kelvin | deg K | K | unit_K | 1 |
Source code is available when you buy a Commercial licence.
Not a member, then Register with CodeCogs. Already a Member, then Login.
You must login to leave a messge