如何根据小时数计算金额? [英] how to calculate Amount based on number of hours?
本文介绍了如何根据小时数计算金额?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如何根据小时数计算金额?
假设
例如:
一些X(小时)= Y(价格),
2X =价格?
3X =价格?
.....
.....
24小时=价格?
.....
3天=价格?
.....
.....
10天=价格?
提前thanx..
how to calculate Amount based on Number of hours?
suppose
for example:
some X(hours)= Y(price),
2X=price?
3X=Price?
.....
.....
24Hours=Price?
.....
3Days=Price?
.....
.....
10days=Price?
thanx in advance..
推荐答案
尝试以下逻辑:
Try this logic:
decimal _duration = 3; //the input time
decimal price = 15; //As I noticed there is 15/- raise on doubling hours.
decimal Amount = (_duration / 3) * price;
希望这会有所帮助.
告诉我我是否弄错了.我会改正的.
Hope this helps.
Tell me if I got you wrong. I''ll correct it.
您好,Sandeep,
我认为您想根据小时数计算工资,如果这样的话,此链接可能会对您有所帮助-
基于小时的工资计算 [
Hi Sandeep,
I think you want to calculate salary on the basis of hours if so, this link might help you-
salary-calculation on basis of hours[^]
这篇关于如何根据小时数计算金额?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文