Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
C
comp2212-cw-2021
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Package registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
PLC
comp2212-cw-2021
Commits
8410239d
Commit
8410239d
authored
4 years ago
by
pm3g19
Browse files
Options
Downloads
Patches
Plain Diff
Added solutions to remaining problem files.
parent
5585af98
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
pr10.cql
+5
-2
5 additions, 2 deletions
pr10.cql
pr8.cql
+9
-0
9 additions, 0 deletions
pr8.cql
pr9.cql
+13
-0
13 additions, 0 deletions
pr9.cql
with
27 additions
and
2 deletions
pr10.cql
+
5
−
2
View file @
8410239d
.in
B:1
S:3,
T:3
.out
B;
\ No newline at end of file
S x T;
filter (\(r) -> r[1]==r[2] and r[5]==r[6]);
map (\(r) -> r[3,4]);
This diff is collapsed.
Click to expand it.
pr8.cql
+
9
−
0
View file @
8410239d
.in
P:4,
Q:4
.out
P x Q;
filter (\(r) -> r[4]==r[8]);
let f = \(p,q) -> if (isEmpty(q)) then p else q;
map (\(r) -> [f(r[1],r[5]), f(r[2], r[6]), f(r[3], r[7]), f(r[4], r[8])]);
This diff is collapsed.
Click to expand it.
pr9.cql
+
13
−
0
View file @
8410239d
.in
R:2
.out
R x R x R;
filter ( \(r) ->
r[2] == r[3]
and
r[4] == r[5]
);
map (\(r) -> r[1,6]);
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment