由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
JobHunting版 - how to charge commission for trades of stocks ? (转载)
相关主题
5个不成功的onsite经历请教leetcode Combination Sum II的code,谢谢。
SQL combine two columns from two different tables no shared columnsa problem from leetcode: high efficiency algorithm for combinations problem
面试就是面试问题,跟实际问题差太远Interview question: N-sum
A家面试题Combination Sum II哪里做错了
a question about combination关于结果除掉重复的问题请教
找硬币的经典问题小公司的offer
这题也可以DP 解吧?hadoop的combiner和partitioner的顺序是什么呢?
求教 leetcode上OJ 的Combination Sum II 解法CS: print all combination from an array
相关话题的讨论汇总
话题: commission话题: trades话题: 500话题: ibm话题: ko
进入JobHunting版参与讨论
1 (共1页)
m****r
发帖数: 141
1
【 以下文字转载自 Quant 讨论区 】
发信人: mitcar (mitcar), 信区: Quant
标 题: how to charge commission for trades of stocks ?
发信站: BBS 未名空间站 (Thu May 17 22:24:38 2012, 美东)
I am new to stock trading. So, I have a basic question about how to charge
commission for trades of stocks.
This is an example question abstracted from an interview, which has been
done .
Commission is charged for customers when they trade .
An order can be broken up into several trades.
The commission is based on the number of shares executed for the order.
How to compute the commission for the trades below:
Commission Schedule
<= 500 shares .013/share
> 500 shares .008/share
Order Number Symbol Quantity Commission
1 IBM 450 ?
1 IBM 150 ?
3 INTC -500 ?
4 KO 1,000 ?
4 KO -950 ?
My solution:
Order Number Symbol Quantity Commission
1 IBM 450 450 * 0.013
1 IBM 150 150 * 0.013
3 INTC -500 500 * 0.013
4 KO 1,000 1000 * 0.008
4 KO -950 950 * 0.008
No matter buy or sell, the commission should be charge for each trade. So,
they should not be charged by combining the same stock trade.
For example, IBM should not be charged by 450+150 = 600. It should be
charged for 2 trades separately.
I doubt that KO's 1000 should be charged by 500 * 0.013 + 500 * 0.008 for
the trade 1000 ?
it depends on how to understand the Commission Schedule
<= 500 shares .013/share
> 500 shares .008/share
?
For a 1000 shares trade, it is charged by 500 * 0.013 + (1000 - 500) * 0.008
?
Any help is appreciated.
Thanks !
1 (共1页)
进入JobHunting版参与讨论
相关主题
CS: print all combination from an arraya question about combination
问个 combination 问题找硬币的经典问题
generate unique integer ID from columns in SQL table这题也可以DP 解吧?
Stock Options 还要自己花钱买吗求教 leetcode上OJ 的Combination Sum II 解法
5个不成功的onsite经历请教leetcode Combination Sum II的code,谢谢。
SQL combine two columns from two different tables no shared columnsa problem from leetcode: high efficiency algorithm for combinations problem
面试就是面试问题,跟实际问题差太远Interview question: N-sum
A家面试题Combination Sum II哪里做错了
相关话题的讨论汇总
话题: commission话题: trades话题: 500话题: ibm话题: ko