实施文件 [英] implemention file
本文介绍了实施文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
请帮帮我
please help me
展开 | 选择 | Wrap | < span class =codeLinkonclick =LineNumbers(this);>行号
推荐答案
如果不了解你班级在做什么,我们可以'不知道这是否是正确的实现。但是,我可以告诉你,既然你的PRE是大小> 0,你不需要使用assert语句。每次使用该函数时,您都可以假定前提条件为真。因此,您可以假设大小始终> 0.如果你知道可以为大小输入一个非正数,你可以考虑一个不同的前提条件。
Without understanding what your class is doing, we can''t tell if this is the proper implementation. I can tell you, however, that since your PRE is size > 0, you don''t need to use the assert statement. A precondition is something you can assume to be true every time the function is used. Thus, you may assume that size is always > 0. If you know that it is possible to enter a non-positive number for size, you may consider a different precondition.
please帮帮我
please help me
展开 | 选择 | Wrap | 行号
我不理解实现文件。我必须填写前置条件和后置条件和代码。我试过但我不确定那些。
文件:throttle.cpp
i did not understand implemention file. i have to fill precondition and postcondition and code. I tried but i am not sure about those.
File: throttle.cpp
展开 | 选择 | Wrap | 行号
这篇关于实施文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文