Jump to content

Google Calculator Percentage xxx% of xxx


Recommended Posts

I often use Google to calculate percentage fast i.e. "2,35% of 195"

I use it in German "2,35% von 195" ;)

 

Is there a way to get this without going to google and have a result in alfred? Or is there a workflow?

 

Thanks in advance for you help and reply.

Link to comment

I often use Google to calculate percentage fast i.e. "2,35% of 195"

I use it in German "2,35% von 195" ;)

 

Is there a way to get this without going to google and have a result in alfred? Or is there a workflow?

 

Thanks in advance for you help and reply.

 

Hey there. I created a workflow that does this (and a few other things), called QuickCalc. It still needs some work (there are a few bugs lingering around), but it should be able to accomplish what you're asking for.
 
It doesn't automatically detect locales, so you'll need to manually set the thousands/decimal separators. In Alfred's preferences, find QuickCalc, double click the "qc" script filter, and set the script to the following:
 
export THOUSANDS_SEPARATOR='.'
export DECIMAL_SEPARATOR=','
/usr/bin/ruby main.rb "{query}"

I just added support for those separators today, so let me know if you find any issues with it.

 

Oh, and one downside to setting the separators like this is that you'll have to re-enter them when you update the workflow. I'll try to find a better solution for that.

Edited by Clinton Strong
Link to comment

Alfred can do on its own this if you're prepared to treat percentages as the fractions they are.

 

Type 295 * 0.0235 and Alfred will do the business. The default in Alfred's calculator is to use the OS X locale-specific separator, so if your user account is set to German language and formats, 295 * 0,0235 should give you the desired result.

Link to comment

Alfred can do on its own this if you're prepared to treat percentages as the fractions they are.

 

Type 295 * 0.0235 and Alfred will do the business. The default in Alfred's calculator is to use the OS X locale-specific separator, so if your user account is set to German language and formats, 295 * 0,0235 should give you the desired result.

 

The Google Suggest workflow will do this as well.

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...