Translate the following json description of an interaction with HTML canvas into…
- User
Translate the following json description of an interaction with HTML canvas into javascript
{ "version": 5, "elem_info_by_key": { "$5": { "type": "HTMLCanvasElement", "width": 300, "height": 150 } }, "frames": [ [ ["$5","getContext",["\"2d"],"$6"], ["$6","setTransform",[1,0,0,1,0,0]], ["$5","set width",[1588]], ["$5","set height",[2246]], ["$6","clearRect",[-100000000,-100000000,200000000,200000000]], ["$6","save",[]], ["$6","scale",[2,2]], ["$6","translate",[-5,-5]], ["$6","set strokeStyle",["\"rgba(0,0,0,1)"]], ["$6","beginPath",[]], ["$6","moveTo",[93,137]], ["$6","lineTo",[741,137]], ["$6","stroke",[]] ] ], "snapshots": {} } - Assistant
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.