Skip to content

Instantly share code, notes, and snippets.

@Jules-Baratoux
Jules-Baratoux / auto_ptr.cpp
Last active August 29, 2015 14:21
Homework #5 – auto_ptr
#include <cstdlib>
#include <cassert>
#include <typeinfo>
#include "auto_ptr.hh"
int main(int argc, char const *argv[])
{
struct X {};
struct Y : public X {};
@Jules-Baratoux
Jules-Baratoux / bitree.c
Last active May 10, 2022 16:01
Homework #6 – Tree
/*
* bitree.c
*/
#include <stdlib.h>
#include <string.h>
#include "bitree.h"
void bitree_init(BiTree *tree, void(*destroy)(void *data)) {
@Jules-Baratoux
Jules-Baratoux / CheckingAccount.h
Last active August 29, 2015 14:21
Homework #4 – Minimizing Compile-time Dependencies
// CheckingAccount.h
#pragma once
#ifndef CHECKINGACCOUNT_H
#define CHECKINGACCOUNT_H
#include <iosfwd>
using std::ostream;
#include <list>
using std::list;
@Jules-Baratoux
Jules-Baratoux / chtbl.c
Last active August 29, 2015 14:21
Homework #5 – Chained hash table
/*
* chtbl.c
*/
#include <stdlib.h>
#include <string.h>
#include "list.h"
#include "chtbl.h"
void chtbl_destroy(CHTbl *htbl) {
@Jules-Baratoux
Jules-Baratoux / hw4.cpp
Created May 8, 2015 01:19
Homework #4 – Minimizing Compile-time Dependencies
init
@Jules-Baratoux
Jules-Baratoux / Instructions.txt
Created April 30, 2015 00:25
Homework #3 – OI File Manager
Directory Details - Due April 29th by 11:59 PM PT
Attached Files:
File DirectorySelectionAndReporting.png (74.973 KB)
Create a program that integrates with the OI File Manager to allow a user to select a directory from their Android device's filesystem. Once a directory has been selected the App shall display the details of the selected directory including a list of its contents (this could become long… consider incorporating a ScrollView). Please see the attached mockup diagram (available on the View/Complete Assignment page) for more information and contact me with any questions.
OI File Manager Guidance
=====================
The OI File Manager can be downloaded/installed directly from the Android Marked on devices that support it.
To install the OI File Manager on an emulator image...
@Jules-Baratoux
Jules-Baratoux / format.h
Last active August 29, 2015 14:20
Homework #4 – Stacks
#if -0
// ----------------------------------------------------------------------------
// SYNOPSYS
// ----------------------------------------------------------------------------
char* format(const char* format, ...);
int fmtlen(const char* ptr, ...);
// ----------------------------------------------------------------------------
@Jules-Baratoux
Jules-Baratoux / Car.c
Last active August 29, 2015 14:20
Homework #3
#include <stdlib.h>
#include <stdio.h>
#include "sort.h"
#define MAX_STRING_LENGTH 8
typedef struct Car_
{
char make[MAX_STRING_LENGTH];
char model[MAX_STRING_LENGTH];
@Jules-Baratoux
Jules-Baratoux / hw3.cpp
Last active August 29, 2015 14:19
Homework #3 – Stream Processing Algorithm
#include <cassert>
#include <cctype>
using ::toupper;
using ::isdigit;
#include <cstring>
using std::strpbrk;
#include <string>
using std::string;
@Jules-Baratoux
Jules-Baratoux / Queue.cpp
Last active August 29, 2015 14:19
Homework #2 – Queue Container
#include <cstdlib>
using std::size_t;
#include <cassert>
#include <cstring>
using ::memmove;
#include <new>
using std::bad_alloc;
using std::nothrow;