I'd suggest starting with LZ77: http://en.wikipedia.org/wiki/LZ78[^]
- It is one of the earlier most widespread lossless algo.
- It has been the base for many other algo.
- The compress and decompress code can be done in less than 100 lines of code.
It might take a while, but get a copy of the code and study it until you understand what every single line is doing. Then try to modify it and understand how all the parameters are inter-related.
The idea that I can be presented with a problem, set out to logically solve it with the tools at hand, and wind up with a program that could not be legally used because someone else followed the same logical steps some years ago and filed for a patent on it is horrifying.
- John Carmack
Everytime the player collides with an asteroid, the gamestate is set to loseScreen, and when the loseScreen is the gamestate, the lose() function is continually called until the gamestate changes.
Inside the lose() function, this code draws the animated spritesheet, which runs through the 16 frame animation. It should always start from frame 0, but it doesn't always. Sometimes it starts at frame 10, and only runs for 6 frames before finishing. That's the issue. The code inside the lose() function to draw the explosion animation is as follows:
In a C# 2008 application, I need to write code that will generate the following xml. Since
I am new to working with xml, I am wondering if you can tell me and/or
point me to a reference that will show me how to generate the following xml:
<xs:element name ="PckId" type="ept:PackId"/>
<xs:element name ="FDocs" type="ept:FDocs" minOccurs="0" maxOccurs="10"/>
<xs:documentation> Refer to the attributes doc</xs:documentation>
<xs:element name="FDocMetadata" type="ept:FDocAttr">
<xs:element name="attachmentId" type="ept:AttachmentId"/>
In a C# 2010 desktop/console application, I am currently using linq to sql to connect to a sql server 2008 database. So far in this application, I have used straight linq to connect to the database. However now I need to obtain data from various tables so that the data can be setup for a new user to access the data. The database people at my job say it is easier to write the logic using a sql script they can give me.
Thus my question is, can linq to sql use 'stright sql' somehow? Basically can I have linq to sql use a stored procedure? If so, can you tell me and/or point me to a reference that will show me how linq to sql can use a stored procedure?
Last Visit: 31-Dec-99 19:00 Last Update: 9-Feb-16 21:25