如何在opl项目中的.data中连接字符串?

问题描述 投票:0回答:1

在我的 .dat 中,我有:

string1 = "Hola";
string2 = "Mundo";

如何连接 string1 + string2?

cplex opl
1个回答
0
投票

您可以使用OPL脚本

string string1 = "Hola";
string string2 = "Mundo";
string string3;

execute
{
  string3=string1+string2;
  writeln(string3);
}

给予

HolaMundo
© www.soinside.com 2019 - 2024. All rights reserved.