Вверх ↑
Ответов: 327
Рейтинг: 5
#1: 2013-05-05 04:12:27 ЛС | профиль | цитата
iarspider писал(а):

если я правильно понял о чем ты, то может тогда вот так?
[flood]
Add(StrMask,12907412,420,175)
{
Mask="*x*"
link(onFalse,10644848:Method,[(468,181)(468,118)])
link(onTrue,7696344:doCompare,[])
AddHint(-2,-45,28,13,Mask)
}
Add(StrMask,7696344,469,182)
{
Mask="*x^*"
link(onFalse,15575904:Method,[])
link(onTrue,835170:Method,[(513,195)(513,223)])
AddHint(4,-37,34,13,Mask)
}
Add(PointHint,10644848,525,102)
{
Info=#45:ловим число, без "х" и записываем в память №3|
Width=267
link(Event,9233470:In,[])
}
Add(Memory,14784245,308,574)
{
Default=Integer(0)
}
Add(PointHint,10842148,154,109)
{
Info=#16:2x^3+15x^2+24x+3|
Width=120
}
Add(Replace,3823100,294,175)
{
SubStr="-"
DestStr="+-"
link(onReplace,11575513:doEnum,[])
AddHint(-19,-38,18,13,SubStr)
AddHint(21,-38,24,13,DestStr)
}
Add(Str_Enum,11575513,343,175)
{
Delimiter="+"
link(onEnum,12907412:doCompare,[])
link(onEndEnum,12042786:doCalc,[(405,188)(405,335)])
AddHint(1,54,21,13,Delimiter)
}
Add(PointHint,15575904,525,172)
{
Info=#27:"х" без степени в память №2|
Width=169
link(Event,9141330:doSplit,[])
}
Add(Memory,13473032,308,497)
{
Default=Integer(0)
}
Add(PointHint,835170,525,207)
{
Info=#17:"x^n" в память №1|
Width=127
link(Event,13042446:doSplit,[])
}
Add(Memory,10648129,308,420)
{
Default=Integer(0)
}
Add(LineBreak,10476648,266,420)
{
Caption="1"
Color=-16777203
link(Out,10648129:doValue,[])
Primary=[6670235,434,-196]
}
Add(LineBreak,443595,266,574)
{
Caption="3"
Color=32896
link(Out,14784245:doValue,[])
Primary=[9233470,532,-462]
}
Add(LineBreak,16400957,266,497)
{
Caption="2"
Color=12639424
link(Out,13473032:doValue,[])
Primary=[14365848,476,-308]
}
Add(StrPart,9141330,700,182)
{
Char="x"
Point(onNotFound)
link(onPart,14365848:In,[])
link(onNotFound,11182288:In,[(737,202)(737,209)])
}
Add(StrPart,13042446,658,217)
{
Char="x"
Point(onNotFound)
link(onPart,6670235:In,[])
link(onNotFound,7127967:In,[(695,237)(695,244)])
}
Add(InfoTip,13423355,259,399)
{
Info=#22:Начальное значение "0"|
Width=148
Height=242
}
Add(LineBreak,2131722,266,434)
{
link(Out,10648129:doClear,[(302,440)(302,433)])
Primary=[14831356,-119,-273]
}
Add(LineBreak,8931054,266,511)
{
link(Out,13473032:doClear,[(302,517)(302,510)])
Primary=[11182288,476,-308]
}
Add(LineBreak,9084375,266,588)
{
link(Out,14784245:doClear,[(302,594)(302,587)])
Primary=[7127967,434,-350]
}
Add(If_else,478098,742,329)
{
Type=4
Op2=Integer(0)
link(onTrue,7654559:doEvent1,[])
link(onFalse,6498827:doMessage,[(813,342)(813,380)(758,380)(758,412)])
}
Add(MathParse,12042786,644,329)
{
DataCount=3
MathStr="%2^2-4*(%1)*(%3)"
Point(doMathStr)
link(onResult,478098:doCompare,[])
link(X1,1917670:Var,[])
link(X2,13984154:Var,[])
link(X3,14576856:Var,[])
AddHint(-131,-17,98,13,MathStr)
}
Add(MathParse,15883397,896,329)
{
DataCount=3
MathStr="(-1*(%2)+sqrt(%3))/(2*(%1))"
link(onResult,9147970:doStrCat,[])
link(X1,8246550:Var,[])
link(X2,7465219:Var,[])
link(X3,11745693:Var,[])
AddHint(-56,-63,138,13,MathStr)
}
Add(MathParse,9510999,896,392)
{
DataCount=3
MathStr="(-1*(%2)-sqrt(%3))/(2*(%1))"
link(onResult,3312515:doStrCat,[])
link(X1,11569385:Var,[])
link(X2,15324942:Var,[])
link(X3,3207853:Var,[])
AddHint(-52,65,135,13,MathStr)
}
Add(LineBreak,3675561,308,469)
{
Type=1
Color=-16777203
link(Data,16643565:Var2,[])
Primary=[1917670,336,-161]
}
Add(LineBreak,10180375,308,546)
{
Type=1
Color=12639424
link(Data,15120722:Var2,[])
Primary=[13984154,343,-238]
}
Add(LineBreak,16679392,308,623)
{
Type=1
Color=32896
link(Data,14784245:Value,[])
Primary=[14576856,350,-315]
}
Add(Message,6498827,763,406)
{
Message="Решений нет"
AddHint(-4,-23,80,13,Message)
}
Add(GetDataEx,15120722,308,532)
{
link(Data,13473032:Value,[])
}
Add(GetDataEx,16643565,308,455)
{
link(Data,10648129:Value,[])
}
Add(LineBreak,11360768,315,469)
{
Type=1
Color=-16777203
link(Data,8507806:Var2,[])
Primary=[8246550,581,-161]
}
Add(LineBreak,9792935,315,546)
{
Type=1
Color=12639424
link(Data,13059354:Var2,[])
Primary=[7465219,588,-238]
}
Add(LineBreak,10561279,644,378)
{
Type=1
Color=255
link(Data,5654089:Var2,[])
Primary=[11745693,266,-70]
}
Add(GetDataEx,8507806,315,455)
{
Angle=3
link(Data,16643565:Var3,[])
}
Add(LineBreak,15911194,322,469)
{
Type=1
Color=-16777203
link(Data,8507806:Var3,[(328,460)])
Primary=[11569385,574,-98]
}
Add(GetDataEx,13059354,315,532)
{
Angle=3
link(Data,15120722:Var3,[])
}
Add(LineBreak,14521491,322,546)
{
Type=1
Color=12639424
link(Data,13059354:Var3,[(328,537)])
Primary=[15324942,581,-175]
}
Add(GetDataEx,5654089,644,364)
{
link(Data,12042786:Result,[])
}
Add(LineBreak,11436724,651,378)
{
Type=1
Color=255
link(Data,5654089:Var3,[(657,369)])
Primary=[3207853,259,-7]
}
Add(Memo,8888921,1092,329)
{
Left=1140
Top=360
}
Add(Hub,7654559,854,329)
{
link(onEvent1,15883397:doCalc,[])
link(onEvent2,9510999:doCalc,[(882,342)(882,398)])
}
Add(StrCat,9147970,952,329)
{
Str1="x1="
link(onStrCat,12369709:doWork2,[])
link(Str2,15883397:Result,[(965,319)(993,319)(993,368)(902,368)])
AddHint(48,-29,32,13,Str1)
}
Add(StrCat,3312515,952,392)
{
Str1="x2="
link(onStrCat,12369709:doWork3,[(1012,398)])
link(Str2,9510999:Result,[(965,380)(997,380)(997,439)(902,439)])
AddHint(66,37,32,13,Str1)
}
Add(HubEx,12369709,1008,329)
{
link(onEvent,8888921:doAdd,[])
}
Add(InfoTip,5005428,714,294)
{
Info=#17:Проверяем на D>=0|
Width=92
Height=81
}
Add(hcButton,653746,56,161)
{
Width=60
Caption="Посчитать"
link(onClick,5199873:doEvent1,[])
}
Add(DoData,13742948,208,175)
{
link(onEventData,3823100:doReplace,[])
link(Data,10842148:Var,[])
}
Add(Hub,5199873,126,161)
{
OutCount=3
link(onEvent1,14831356:In,[])
link(onEvent2,16331721:In,[])
link(onEvent3,13742948:doData,[])
}
Add(LineBreak,4129071,1057,336)
{
link(Out,8888921:doClear,[])
Primary=[16331721,-910,-168]
}
[/flood]
ну подстановку я опустил...
карма: 0

0
файлы: 1code_30946.txt [5.7KB] [107]