Skip to content

Instantly share code, notes, and snippets.

View djmunro's full-sized avatar

David Munro djmunro

View GitHub Profile
function main()
Problem1()
Problem2()
Problem3()
end
function Problem1()
number = 0;
@djmunro
djmunro / main.cpp
Created January 22, 2013 18:41
2110 LAB1
#include <iostream>
#include <string>
using namespace std;
int main()
{
/*
//PART A
// A)
double var_1 = 20.25;
1>arbtriangleinstrument.obj : error LNK2001: unresolved external symbol "public: virtual struct QMetaObject const * __thiscall ArbTriangleInstrument::metaObject(void)const " (?metaObject@ArbTriangleInstrument@@UBEPBUQMetaObject@@XZ)
1>arbtriangleinstrument.obj : error LNK2001: unresolved external symbol "public: virtual void * __thiscall ArbTriangleInstrument::qt_metacast(char const *)" (?qt_metacast@ArbTriangleInstrument@@UAEPAXPBD@Z)
1>arbtriangleinstrument.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall ArbTriangleInstrument::qt_metacall(enum QMetaObject::Call,int,void * *)" (?qt_metacall@ArbTriangleInstrument@@UAEHW4Call@QMetaObject@@HPAPAX@Z)
1>C:\Users\dave\Desktop\CR2\bin\Debug\easypaint.exe : fatal error LNK1120: 3 unresolved externals
import re
import sys
import json
import itertools
from collections import Counter
from collections import defaultdict
SIGNALS = []
METHOD_CALLS = []
def print_grid(tuple, data):
t1 = max([len(str(x[t])) for x in data])
print_grid(('Function', 'Occurences' 'Sender'), [(x['function'], x['sender']) for x in messages if 'function' in x])
def print_grid(columns, values):
# pop columns on top of values, since we want to print them as well
values = [columns] + values
# calculate the format string for printing a row
row_format = ''
for index in range(len(columns)):
longest = max([len(str(row[index])) for row in values])
row_format += '{:' + str(longest) + '} '
#include <stdio.h>
#include <fcntl.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <unistd.h>
int main (int argc, char *argv[])
{
int fd;
from pageobjects.basepageobject import BasePageObject
from pageobjects.basepageelement import BasePageElement
class BrowseElement(BasePageElement):
def __init__(self, type="all", driver):
self.driver = driver
if type.lower() is "all":
On the clock screen: False
Traceback (most recent call last):
File "hmi.py", line 42, in <module>
print('Found button: {}'.format(**get_button(data, ButtonDebugID.CLOSE)))
File "hmi.py", line 36, in get_button
return next(x['name'] for x in get_all_screens(data) if x['name'] == button.value)
File "hmi.py", line 36, in <genexpr>
return next(x['name'] for x in get_all_screens(data) if x['name'] == button.value)
TypeError: string indices must be integers
using System;
using System.IO;
using Harman.Generic.Framework;
namespace Harman.GM.Info3.TestSupport.Extended
{
public enum Waveband
{
Fm,
Am,