ExamplesR
Sun Feb 12 2023 00:42:47 GMT+0000 (Coordinated Universal Time)
Saved by
@Achilles_17
class R{
String r1;
R r2;
R(String r1, R r2){
this.r1 = r1;
this.r2 = r2;
}
}
class ExamplesR{
R agentA = new R("agent A", R);
R agentB = new R("agent B", agentA);
}
// 1. The reason I don't think it was possible to construct an example of the R object is because
// R is not a dataype. It does not seem possible to create a new piece of data from a type that does
// not exist.
// 2. I do think it would be possible to construct an example of a reply to a reply to a tweet given the current class
// structure on Drill3. I think it is possible because you could create a ReplyTweet object that takes another ReplyTweet object
// as its argument and therefore replies to a reply, but it is impossible to do so before an object of that type is defined as is
// apparent in the above example
content_copyCOPY
Comments