本程序由主窗体forml和子窗体form2组成,设计界面如下图所示:
主窗体上建立的对象有Imagel. Buttonl(加载图片),Button2(退出)、OpenDiaiogl。
子窗体上建立的对象有Labell. BitBtml(Yes),BitBtm2(No)
单云“加载图片”按钮,会弹出打开文件对话框。用户指定一个图像文件后,图像加载到
Imagel显示区中。
单击“退出”按钮,会弹出确认对话框(Form2)。如果用户按“Yes”键,程序结束;如果按
"No"键,返回主窗体。
下面是Unitl的代码部分,请在下划线处完成程序填空。
__________________________________________________________________________________
implementation
($R * . dfm}
uses①______;
procedure TForml. ButtonlClick (Sender: TObject);
begin
if②_______________________then
Imagel. Picture. LoadFromFile(③______________________)
end;
procedure TForml. Buttot.2Click (Sender: TObject);
begin
if④_________________________= mrYes then
⑤_____________;
end;
end.
___________________________________________
Tablet Co makes two types of tablet computer, the Xeno (X) and the Yong (Y). X currently generates a contribution of $30 per unit and Y generates a contribution of $40 per unit. There are three main stages of production: the build stage, the program stage and the test stage. Each of these stages requires the use of skilled labour which, due to a huge increase in demand for tablet computers over recent months, is now in short supply. The following information is available for the two products:
Tablet Co is now preparing its detailed production plans for the next quarter. During this period it expects that the skilled labour available will be 30,000 hours (1,800,000 minutes) for the build stage, 28,000 hours (1,680,000 minutes) for the program stage and 12,000 hours (720,000 minutes) for the test stage. The maximum demand for X and Y over the three-month period is expected to be 85,000 units and 66,000 units respectively. Fixed costs are $650,000 per month.
Due to rapid technological change, the company holds no inventory of finished goods.
Required:
(a) On the graph paper provided, use linear programming to calculate the optimum number of each product which Tablet Co should make in the next quarter assuming it wishes to maximise contribution. Calculate the total profit for the quarter. (14 marks)
(b) Calculate the amount of any slack resources arising as a result of the optimum production plan and explain the implications of these amounts for decision-making within Tablet Co. (6 marks)