Challenge #238: Ideal Gases Don't Exist
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
A solution to last week's challenge can be found here.
The Ideal Gas law is a staple of Chemistry classes around the world. You may recall that it is defined as PV=nRT; where P = pressure, V = volume, n = the number of moles, R = the ideal gas constant, and T = temperature.
This week's challenge is to create an app that requires an end user to select 3 checkboxes and enter values, then produces the final variable and units as a result.
For the sake of simplicity, we will use static units for all variables. Pressure in ATM, Volume in Liters Temperature in Kelvin, and R = 0.082057338. Use 3 decimal places on the inputs. You can check your math here.
Bonus: Add in error messages if the user selects too few or too many checkboxes.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Cool challenge! I managed to build in error-checking, and everything seems to be working swimmingly. I'm sure using interface tools isn't a common occurrence for many developers, so challenges like this are excellent practice.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Fun way to start a Monday.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Nice Challenge! I also added an error for if someone selected all 4 variables
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Really fun challenge 😀
The bonus part was something new to me had fun cracking it was a great learning configuring the error tool.

App:

Error message

You got to select exactly 3 parameters and you get the fourth missing one 😉
App Rerun:
Output:

Cheers and Happy Analyzing 😀
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
I don't use interface tools in my daily business, great opportunity to practise.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Well that was a GAS!!!!