<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>http://www.lensovet.net/~sysadmin/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Lensovet</id>
	<title>lensowiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="http://www.lensovet.net/~sysadmin/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Lensovet"/>
	<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/Special:Contributions/Lensovet"/>
	<updated>2026-05-02T20:14:16Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.31.16</generator>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Priceline_Rewards_credit_cards&amp;diff=24460</id>
		<title>Priceline Rewards credit cards</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Priceline_Rewards_credit_cards&amp;diff=24460"/>
		<updated>2025-05-17T21:45:47Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: it was good while it lasted&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Barclays issued a priceline rewards credit card at least as far back as 2017, though it's impossible to find info on it now. Its earnings structure was quite simple:&lt;br /&gt;
&lt;br /&gt;
* 5 points per dollar on Priceline purchases&lt;br /&gt;
* 1 point per dollar on everything else&lt;br /&gt;
&lt;br /&gt;
Things got more interesting, however, once you started to redeem those points, because the redemption values were ''also'' different between priceline purchases vs. everything else:&lt;br /&gt;
&lt;br /&gt;
* 1.5% dollar value for points redeemed against priceline purchases&lt;br /&gt;
* 1% dollar value for points redeemed against all other purchases&lt;br /&gt;
* 10% point redemption refund on all redemptions&lt;br /&gt;
&lt;br /&gt;
This meant that the effective cash back rate on priceline purchases when redeemed against priceline purchases was 5 × 1.5 / 0.9 = 8.33%. If that sounds too good to be true, just do the math on a hypothetical $1000 priceline purchase: you earn 5000 points, which corresponds to a $75 redemption against that purchase, but when you go to use the redemption, only 4500 points are used. The remaining 500 points are worth $7.50 when redeemed against a pricelline purchase, so you effectively get $82.50 worth of rewards against a $1000 purchase (though those points would only &amp;quot;cost&amp;quot; 450, since you'd get another 10% back on that redemption, and on and on).&lt;br /&gt;
&lt;br /&gt;
Note that you could also &amp;quot;cross-redeem&amp;quot;, i.e. take points from a regular purchase and redeem them against a priceline purchase and vice versa. This gave you an effective rate of 1.67% for regular purchases redeemed against priceline ones and 5.5% for priceline purchases redeemed against regular ones.&lt;br /&gt;
&lt;br /&gt;
Someone at Barclays probably eventually realized this was too good to be true too, and so in 2022 they introduced the new Priceline VIP Rewards credit card. The earning structure, on paper, got better, because in addition to the earnings with the original card, gas and restaurant purchases would now earn 2 points per dollar spent. They added a rather dubious VIP Gold status as a &amp;quot;perk&amp;quot;, as well as reimbursement of TSA PreCheck or Global Entry application fees once your annual spend exceeds $10,000. But all of the redemption bonuses went away — all purchases now redeemed at 1% and there was no redemption refund. So even non-priceline purchases got a worse redemption rate on this card than the old one!&lt;br /&gt;
&lt;br /&gt;
Of course, the old card is no longer available. However, the reason this matters is because for those who still have the old card, Barclays will tempt you to &amp;quot;upgrade&amp;quot; with this brilliant wording:&lt;br /&gt;
&lt;br /&gt;
{{quote|Update your account to the Priceline VIP Rewards™ Visa® Card and enjoy extraordinary new benefits and services.}}&lt;br /&gt;
&lt;br /&gt;
The touted &amp;quot;benefits&amp;quot; are as follows:&lt;br /&gt;
&lt;br /&gt;
* Reduction of effective priceline redemption rate by 40%&lt;br /&gt;
* Reduction of effective other purchase redemption rate by 10%&lt;br /&gt;
* Increase of effective redemption rate for gas and restaurant purchases by 80%&lt;br /&gt;
* An additional 1% discount for the GE fee once every 5 years (since GE costs $100 and you have to put at least $10,000 of spend on the card to get it)&lt;br /&gt;
&lt;br /&gt;
Given the huge devaluation in priceline redemptions and the multitude of other cards that give a straight 2% cash back on all purchases, there is absolutely no reason for anyone with the older card to &amp;quot;upgrade&amp;quot; to the new one.&lt;br /&gt;
&lt;br /&gt;
On April 30, 2025, Barclays sent an email to existing cardholders stating that their card will be automatically converted on July 2, 2025. The earning structure would change on that date; however, redemption values against Priceline charges would remain unchanged until September 2, 2025. The 10% rebate on redemptions, however, would be terminated on July 2.&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=LG_4922W5A057G_dimensions&amp;diff=24459</id>
		<title>LG 4922W5A057G dimensions</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=LG_4922W5A057G_dimensions&amp;diff=24459"/>
		<updated>2024-11-18T04:51:40Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: power hole updates&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;I purchased an open-box LG microwave oven which did not include the upper or wall mounting templates. It seemed silly to spend $20 for a piece of paper, so thanks to a [https://www.youtube.com/watch?v=V7G6Na-7F0w YouTube video I found of someone else installing theirs], I was able to extract the necessary measurements.&lt;br /&gt;
&lt;br /&gt;
Holes J and K for the bolts to attach the microwave to the bottom of the cabinet over it are 10⅜&amp;quot; from the back wall. J (left side) is 11⅞&amp;quot; from the centerline; K (right side) is 13 7/16&amp;quot; from the centerline. Both of these holes should be ⅜&amp;quot; (technically the bolts you use are ¼&amp;quot;, so depending on how good your tolerances are, you might be able to get away with a ¼&amp;quot; hole).&lt;br /&gt;
&lt;br /&gt;
The power supply hole (M) is 5⅛&amp;quot; from the wall and 6⅛&amp;quot; from the centerline. It is 2&amp;quot; in diameter. In my experience, the wall distance was closer to 5½&amp;quot; and a 1 3/16&amp;quot; hole was more than sufficient (I had a hole saw in that size already and used it).&lt;br /&gt;
&lt;br /&gt;
The roof vent opening (L) is 6½&amp;quot; on either side of the centerline and 4½&amp;quot; for a recessed cabinet (at least ¾&amp;quot; recess) or 5¾&amp;quot; for a flush cabinet.&lt;br /&gt;
&lt;br /&gt;
The wall vent opening (F) is ¼&amp;quot; below the bottom of the cabinet and has dimensions of 4&amp;quot; tall and 12&amp;quot; wide, 6&amp;quot; on either side of the centerline. The centerline should go through the ▽ symbol on the bottom mounting bracket.&lt;br /&gt;
&lt;br /&gt;
Hope this helps someone!&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=LG_4922W5A057G_dimensions&amp;diff=24458</id>
		<title>LG 4922W5A057G dimensions</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=LG_4922W5A057G_dimensions&amp;diff=24458"/>
		<updated>2024-11-17T22:25:46Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: use fraction symbols where possible&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;I purchased an open-box LG microwave oven which did not include the upper or wall mounting templates. It seemed silly to spend $20 for a piece of paper, so thanks to a [https://www.youtube.com/watch?v=V7G6Na-7F0w YouTube video I found of someone else installing theirs], I was able to extract the necessary measurements.&lt;br /&gt;
&lt;br /&gt;
Holes J and K for the bolts to attach the microwave to the bottom of the cabinet over it are 10⅜&amp;quot; from the back wall. J (left side) is 11⅞&amp;quot; from the centerline; K (right side) is 13 7/16&amp;quot; from the centerline. Both of these holes should be ⅜&amp;quot; (technically the bolts you use are ¼&amp;quot;, so depending on how good your tolerances are, you might be able to get away with a ¼&amp;quot; hole).&lt;br /&gt;
&lt;br /&gt;
The power supply hole (M) is 5⅛&amp;quot; from the wall and 6⅛&amp;quot; from the centerline. It is 2&amp;quot; in diameter.&lt;br /&gt;
&lt;br /&gt;
The roof vent opening (L) is 6½&amp;quot; on either side of the centerline and 4½&amp;quot; for a recessed cabinet (at least ¾&amp;quot; recess) or 5¾&amp;quot; for a flush cabinet.&lt;br /&gt;
&lt;br /&gt;
The wall vent opening (F) is ¼&amp;quot; below the bottom of the cabinet and has dimensions of 4&amp;quot; tall and 12&amp;quot; wide, 6&amp;quot; on either side of the centerline. The centerline should go through the ▽ symbol on the bottom mounting bracket.&lt;br /&gt;
&lt;br /&gt;
Hope this helps someone!&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=LG_4922W5A057G_dimensions&amp;diff=24457</id>
		<title>LG 4922W5A057G dimensions</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=LG_4922W5A057G_dimensions&amp;diff=24457"/>
		<updated>2024-11-17T22:23:34Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Created page with &amp;quot;I purchased an open-box LG microwave oven which did not include the upper or wall mounting templates. It seemed silly to spend $20 for a piece of paper, so thanks to a [https:...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;I purchased an open-box LG microwave oven which did not include the upper or wall mounting templates. It seemed silly to spend $20 for a piece of paper, so thanks to a [https://www.youtube.com/watch?v=V7G6Na-7F0w YouTube video I found of someone else installing theirs], I was able to extract the necessary measurements.&lt;br /&gt;
&lt;br /&gt;
Holes J and K for the bolts to attach the microwave to the bottom of the cabinet over it are 10 3/8&amp;quot; from the back wall. J (left side) is 11 7/8&amp;quot; from the centerline; K (right side) is 13 7/16&amp;quot; from the centerline. Both of these holes should be 3/8&amp;quot; (technically the bolts you use are 1/4&amp;quot;, so depending on how good your tolerances are, you might be able to get away with a 1/4&amp;quot; hole).&lt;br /&gt;
&lt;br /&gt;
The power supply hole (M) is 5 1/8&amp;quot; from the wall and 6 1/8&amp;quot; from the centerline. It is 2&amp;quot; in diameter.&lt;br /&gt;
&lt;br /&gt;
The roof vent opening (L) is 6.5&amp;quot; on either side of the centerline and 4.5&amp;quot; for a recessed cabinet (at least 3/4&amp;quot; recess) or 5 3/4&amp;quot; for a flush cabinet.&lt;br /&gt;
&lt;br /&gt;
The wall vent opening (F) is 1/4&amp;quot; below the bottom of the cabinet and has dimensions of 4&amp;quot; tall and 12&amp;quot; wide, 6&amp;quot; on either side of the centerline. The centerline should go through the ▽ symbol on the bottom mounting bracket.&lt;br /&gt;
&lt;br /&gt;
Hope this helps someone!&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Home_improvement&amp;diff=24456</id>
		<title>Home improvement</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Home_improvement&amp;diff=24456"/>
		<updated>2024-11-17T22:11:54Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: + lg template&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Random tidbits through doing home projects.&lt;br /&gt;
&lt;br /&gt;
* [[Home products made in the USA]]&lt;br /&gt;
* [[LG 4922W5A057G dimensions]]&lt;br /&gt;
&lt;br /&gt;
== Connecting Siemens SPDs to a load center ==&lt;br /&gt;
Siemens SPDs ([https://amzn.to/3ICxhhp FS060/FS60], [https://amzn.to/3lQnBXG FS100], [https://amzn.to/3xyFxZh FS140]) come with an NPT thread on the end, which prevents it from being directly connected into a load center knockout as none of those connectors have NPT thread patterns on them. Siemens support was utterly useless, basically saying &amp;quot;well you should go find what you need&amp;quot;. The solution I ended up arriving at was to use a [https://www.homedepot.com/p/3-4-in-Flexible-Elbow-R6441102/202043366 Cantex 3/4 in. Flexible Elbow], which comes with NPT fittings on both ends, and replace the fitting on one end with an [https://www.homedepot.com/p/3-4-in-90-NMLT-Push-Connector-1-Pack-NMLT907-1/202284600 Arlington 3/4 in. 90° SNAP2IT Non-Metallic Push-On Connector] (also [https://amzn.to/3SayYFY available on Amazon], [http://www.aifittings.com/catalog/liquid-tight/90-degree-snap2it-non-metallic-connectors/NMLT907 Arlington spec page]). If you don't need the 90-degree bend, Arlington makes [http://www.aifittings.com/catalog/liquid-tight/snap2it-non-metallic-connectors/NMLT7 a straight variant] too, which you can get [https://amzn.to/3EoJRy7 on Amazon] or [https://www.homedepot.com/p/SNAP2IT-3-4-in-Non-Metallic-NM-Liquid-Tight-Connector-1-pack-NMLT7-1/202284603 HD] (HD for some reason shows 1/2&amp;quot; in the pictures for the 3/4&amp;quot; product).&lt;br /&gt;
&lt;br /&gt;
The Arlington connectors referenced above are made in the US.&lt;br /&gt;
&lt;br /&gt;
== HVAC registers that aren't made in China or Vietnam ==&lt;br /&gt;
Pretty much every HVAC register at your big box store will come from Vietnam or China. If you're looking for something more local, you have a few options:&lt;br /&gt;
&lt;br /&gt;
* [https://www.imperialgroup.ca Imperial Group's] metal registers are made in Canada. They are trivial to get at [https://www.lowes.ca/product/sidewall-ceiling-registers/imperial-10-in-x-6-in-sideceiling-register-2-way-4871464 Lowe's in Canada], but are a bit more challenging to obtain here in the US. Buying them online is an option, but I had a really hard time ordering these from Amazon and having them arrive without damage. One literally was broken in pieces by the time it was at my doorstep. TrueValue carries some of the fancier floor register models (like the wood and satin metal) in some of their stores in New Jersey, but for some reason not the plain vanilla sidewall ones. Note that some of their products are made in China.&lt;br /&gt;
* [https://decorgrates.com Decor Grates] is another Canadian manufacturer, who appears to make all of their products in Canada, unlike Imperial. However, their [https://amzn.to/3YKOs5R wood floor register] did not look as polished to my eyes and had a very flimsy damper mechanism. Their site is also a giant mess, with &amp;quot;No products were found matching your selection&amp;quot; regularly showing up while navigating it.&lt;br /&gt;
* [https://www.ameriflowregisters.com/residential-grds/sidewall-ceiling-registers-grilles AmeriFlow], aka [https://www.hartandcooley.com/grilles-registers-and-diffusers-grd/residential-grds/sidewall-ceiling-register-grilles Hart &amp;amp; Cooley], makes registers in Mexico and can be found in TrueValue stores as well as e.g. [https://www.supplyhouse.com SupplyHouse]. They seem to be the only ones that make registers that are [https://www.hartandcooley.com/products/681-a681/steel-aluminum-1-way-register-ms-damper-1-2-fin-spacing uni-directional], which is unfortunate as it makes no sense to install a two-way (or straight) register at a vent that's in the corner of a room. Ultimately, I did not buy theirs because the lever has a plastic piece, and the registers we had in our house had those plastic pieces break.&lt;br /&gt;
* [https://www.shoemakermfg.com Shoemaker Manufacturing] makes registers in the US. They are impossible to find in brick and mortar stores (except in Washington?). Online you can find them on some websites with absolutely astronomical prices and unrealistic return policies. I did end up ordering [https://amzn.to/3kbF6RK one register] on Amazon (and took the hit for return shipping) just to see what it looked like, but the styling didn't really work in a residential setting. The spacing of the fins was also too wide.&lt;br /&gt;
* [https://www.continentalindustries.com Continental] makes registers in the US, though finding them in stores is a challenge as well. They also make one-way registers. [http://www.hepsales.com HEP Sales] quoted a price of $50.35 for 21RW1006 if buying together with something that they stock. The 2-ways are easier to find online.&lt;br /&gt;
&lt;br /&gt;
== Pulling dryer terminal block screws out of Samsung dryers ==&lt;br /&gt;
I had the pleasure of dropping not one but two terminal screws in our electric Samsung dryer &amp;quot;into&amp;quot; the dryer. Unlike other manufacturers, Samsung makes the housing of the dryer completely enclosed, so you can't simply &amp;quot;roll&amp;quot; the screw to the front like with other dryers and then just pull it out. There is, however, a way to get them out without fully disassembling the thing. Ironically, it relies on another questionable design decision — leveling legs that come all the way out.&lt;br /&gt;
&lt;br /&gt;
The dryer's leveling legs have two curious features — they are made entirely out of plastic (so excessive force will crack or break them) and they can be completely removed from the dryer if you raise them high enough. This latter property allows us to use the holes to fish out the screws.&lt;br /&gt;
&lt;br /&gt;
Tilt the dryer to the side and back to make sure that your fallen screw is in the rear left corner if looking at the front of the dryer. Then, slightly tilt up the dryer at the rear left corner and use a very strong magnet to reach through the hole and grab the screw. Depending on how strong your magnet is, you might need to reach in with your finger first to bring the screw a little closer to the hole.&lt;br /&gt;
&lt;br /&gt;
A final note: if the dryer is mounted on top of the matching pedestal, you will need to screw the legs onto the pedestal when tilting to get the screw into the corner and then unscrew them when tilting to get the screw out.&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Priceline_Rewards_credit_cards&amp;diff=24455</id>
		<title>Priceline Rewards credit cards</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Priceline_Rewards_credit_cards&amp;diff=24455"/>
		<updated>2024-05-15T01:42:36Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Barclays issued a priceline rewards credit card at least as far back as 2017, though it's impossible to find info on it now. Its earnings structure was quite simple:&lt;br /&gt;
&lt;br /&gt;
* 5 points per dollar on Priceline purchases&lt;br /&gt;
* 1 point per dollar on everything else&lt;br /&gt;
&lt;br /&gt;
Things got more interesting, however, once you started to redeem those points, because the redemption values were ''also'' different between priceline purchases vs. everything else:&lt;br /&gt;
&lt;br /&gt;
* 1.5% dollar value for points redeemed against priceline purchases&lt;br /&gt;
* 1% dollar value for points redeemed against all other purchases&lt;br /&gt;
* 10% point redemption refund on all redemptions&lt;br /&gt;
&lt;br /&gt;
This meant that the effective cash back rate on priceline purchases when redeemed against priceline purchases was 5 × 1.5 / 0.9 = 8.33%. If that sounds too good to be true, just do the math on a hypothetical $1000 priceline purchase: you earn 5000 points, which corresponds to a $75 redemption against that purchase, but when you go to use the redemption, only 4500 points are used. The remaining 500 points are worth $7.50 when redeemed against a pricelline purchase, so you effectively get $82.50 worth of rewards against a $1000 purchase (though those points would only &amp;quot;cost&amp;quot; 450, since you'd get another 10% back on that redemption, and on and on).&lt;br /&gt;
&lt;br /&gt;
Note that you could also &amp;quot;cross-redeem&amp;quot;, i.e. take points from a regular purchase and redeem them against a priceline purchase and vice versa. This gave you an effective rate of 1.67% for regular purchases redeemed against priceline ones and 5.5% for priceline purchases redeemed against regular ones.&lt;br /&gt;
&lt;br /&gt;
Someone at Barclays probably eventually realized this was too good to be true too, and so in 2022 they introduced the new Priceline VIP Rewards credit card. The earning structure, on paper, got better, because in addition to the earnings with the original card, gas and restaurant purchases would now earn 2 points per dollar spent. They added a rather dubious VIP Gold status as a &amp;quot;perk&amp;quot;, as well as reimbursement of TSA PreCheck or Global Entry application fees once your annual spend exceeds $10,000. But all of the redemption bonuses went away — all purchases now redeemed at 1% and there was no redemption refund. So even non-priceline purchases got a worse redemption rate on this card than the old one!&lt;br /&gt;
&lt;br /&gt;
Of course, the old card is no longer available. However, the reason this matters is because for those who still have the old card, Barclays will tempt you to &amp;quot;upgrade&amp;quot; with this brilliant wording:&lt;br /&gt;
&lt;br /&gt;
{{quote|Update your account to the Priceline VIP Rewards™ Visa® Card and enjoy extraordinary new benefits and services.}}&lt;br /&gt;
&lt;br /&gt;
The touted &amp;quot;benefits&amp;quot; are as follows:&lt;br /&gt;
&lt;br /&gt;
* Reduction of effective priceline redemption rate by 40%&lt;br /&gt;
* Reduction of effective other purchase redemption rate by 10%&lt;br /&gt;
* Increase of effective redemption rate for gas and restaurant purchases by 80%&lt;br /&gt;
* An additional 1% discount for the GE fee once every 5 years (since GE costs $100 and you have to put at least $10,000 of spend on the card to get it)&lt;br /&gt;
&lt;br /&gt;
Given the huge devaluation in priceline redemptions and the multitude of other cards that give a straight 2% cash back on all purchases, there is absolutely no reason for anyone with the older card to &amp;quot;upgrade&amp;quot; to the new one.&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Home_improvement&amp;diff=24454</id>
		<title>Home improvement</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Home_improvement&amp;diff=24454"/>
		<updated>2024-04-05T18:08:46Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: /* HVAC registers that aren't made in China or Vietnam */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Random tidbits through doing home projects.&lt;br /&gt;
&lt;br /&gt;
* [[Home products made in the USA]]&lt;br /&gt;
&lt;br /&gt;
== Connecting Siemens SPDs to a load center ==&lt;br /&gt;
Siemens SPDs ([https://amzn.to/3ICxhhp FS060/FS60], [https://amzn.to/3lQnBXG FS100], [https://amzn.to/3xyFxZh FS140]) come with an NPT thread on the end, which prevents it from being directly connected into a load center knockout as none of those connectors have NPT thread patterns on them. Siemens support was utterly useless, basically saying &amp;quot;well you should go find what you need&amp;quot;. The solution I ended up arriving at was to use a [https://www.homedepot.com/p/3-4-in-Flexible-Elbow-R6441102/202043366 Cantex 3/4 in. Flexible Elbow], which comes with NPT fittings on both ends, and replace the fitting on one end with an [https://www.homedepot.com/p/3-4-in-90-NMLT-Push-Connector-1-Pack-NMLT907-1/202284600 Arlington 3/4 in. 90° SNAP2IT Non-Metallic Push-On Connector] (also [https://amzn.to/3SayYFY available on Amazon], [http://www.aifittings.com/catalog/liquid-tight/90-degree-snap2it-non-metallic-connectors/NMLT907 Arlington spec page]). If you don't need the 90-degree bend, Arlington makes [http://www.aifittings.com/catalog/liquid-tight/snap2it-non-metallic-connectors/NMLT7 a straight variant] too, which you can get [https://amzn.to/3EoJRy7 on Amazon] or [https://www.homedepot.com/p/SNAP2IT-3-4-in-Non-Metallic-NM-Liquid-Tight-Connector-1-pack-NMLT7-1/202284603 HD] (HD for some reason shows 1/2&amp;quot; in the pictures for the 3/4&amp;quot; product).&lt;br /&gt;
&lt;br /&gt;
The Arlington connectors referenced above are made in the US.&lt;br /&gt;
&lt;br /&gt;
== HVAC registers that aren't made in China or Vietnam ==&lt;br /&gt;
Pretty much every HVAC register at your big box store will come from Vietnam or China. If you're looking for something more local, you have a few options:&lt;br /&gt;
&lt;br /&gt;
* [https://www.imperialgroup.ca Imperial Group's] metal registers are made in Canada. They are trivial to get at [https://www.lowes.ca/product/sidewall-ceiling-registers/imperial-10-in-x-6-in-sideceiling-register-2-way-4871464 Lowe's in Canada], but are a bit more challenging to obtain here in the US. Buying them online is an option, but I had a really hard time ordering these from Amazon and having them arrive without damage. One literally was broken in pieces by the time it was at my doorstep. TrueValue carries some of the fancier floor register models (like the wood and satin metal) in some of their stores in New Jersey, but for some reason not the plain vanilla sidewall ones. Note that some of their products are made in China.&lt;br /&gt;
* [https://decorgrates.com Decor Grates] is another Canadian manufacturer, who appears to make all of their products in Canada, unlike Imperial. However, their [https://amzn.to/3YKOs5R wood floor register] did not look as polished to my eyes and had a very flimsy damper mechanism. Their site is also a giant mess, with &amp;quot;No products were found matching your selection&amp;quot; regularly showing up while navigating it.&lt;br /&gt;
* [https://www.ameriflowregisters.com/residential-grds/sidewall-ceiling-registers-grilles AmeriFlow], aka [https://www.hartandcooley.com/grilles-registers-and-diffusers-grd/residential-grds/sidewall-ceiling-register-grilles Hart &amp;amp; Cooley], makes registers in Mexico and can be found in TrueValue stores as well as e.g. [https://www.supplyhouse.com SupplyHouse]. They seem to be the only ones that make registers that are [https://www.hartandcooley.com/products/681-a681/steel-aluminum-1-way-register-ms-damper-1-2-fin-spacing uni-directional], which is unfortunate as it makes no sense to install a two-way (or straight) register at a vent that's in the corner of a room. Ultimately, I did not buy theirs because the lever has a plastic piece, and the registers we had in our house had those plastic pieces break.&lt;br /&gt;
* [https://www.shoemakermfg.com Shoemaker Manufacturing] makes registers in the US. They are impossible to find in brick and mortar stores (except in Washington?). Online you can find them on some websites with absolutely astronomical prices and unrealistic return policies. I did end up ordering [https://amzn.to/3kbF6RK one register] on Amazon (and took the hit for return shipping) just to see what it looked like, but the styling didn't really work in a residential setting. The spacing of the fins was also too wide.&lt;br /&gt;
* [https://www.continentalindustries.com Continental] makes registers in the US, though finding them in stores is a challenge as well. They also make one-way registers. [http://www.hepsales.com HEP Sales] quoted a price of $50.35 for 21RW1006 if buying together with something that they stock. The 2-ways are easier to find online.&lt;br /&gt;
&lt;br /&gt;
== Pulling dryer terminal block screws out of Samsung dryers ==&lt;br /&gt;
I had the pleasure of dropping not one but two terminal screws in our electric Samsung dryer &amp;quot;into&amp;quot; the dryer. Unlike other manufacturers, Samsung makes the housing of the dryer completely enclosed, so you can't simply &amp;quot;roll&amp;quot; the screw to the front like with other dryers and then just pull it out. There is, however, a way to get them out without fully disassembling the thing. Ironically, it relies on another questionable design decision — leveling legs that come all the way out.&lt;br /&gt;
&lt;br /&gt;
The dryer's leveling legs have two curious features — they are made entirely out of plastic (so excessive force will crack or break them) and they can be completely removed from the dryer if you raise them high enough. This latter property allows us to use the holes to fish out the screws.&lt;br /&gt;
&lt;br /&gt;
Tilt the dryer to the side and back to make sure that your fallen screw is in the rear left corner if looking at the front of the dryer. Then, slightly tilt up the dryer at the rear left corner and use a very strong magnet to reach through the hole and grab the screw. Depending on how strong your magnet is, you might need to reach in with your finger first to bring the screw a little closer to the hole.&lt;br /&gt;
&lt;br /&gt;
A final note: if the dryer is mounted on top of the matching pedestal, you will need to screw the legs onto the pedestal when tilting to get the screw into the corner and then unscrew them when tilting to get the screw out.&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Home_products_made_in_the_USA&amp;diff=24453</id>
		<title>Home products made in the USA</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Home_products_made_in_the_USA&amp;diff=24453"/>
		<updated>2023-06-10T06:33:32Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: /* HVAC */ +registers&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Plumbing ==&lt;br /&gt;
* Most '''Keeney''' plastic tubular sold at Lowe's is made in the US. It is PVC.&lt;br /&gt;
* Home Depot will randomly have '''Oatey''' PP tubular at some locations. For whatever reason, it comes in generic-looking packaging with black and white markings instead of normal-looking branded packaging.&lt;br /&gt;
* Some '''PlumbPak''' plastic tubular (PP) sold on Amazon is made in the US as well, but the product pages can't be relied on for determining this.&lt;br /&gt;
&lt;br /&gt;
== Fasteners ==&lt;br /&gt;
* SPAX screws are made in the US or Germany and sold at both HD and Lowe's. Lowe's tends to have lower prices though their boxes don't include the screw bit in them.&lt;br /&gt;
&lt;br /&gt;
== Electrical ==&lt;br /&gt;
* [https://mulberrymetal.com Mulberry] ''metal'' products are generally made in the US. A limited assortment of their white painted wall plates are sold at HD, but beyond that, you'll have to go to a local electric supply store to find them.&lt;br /&gt;
* Leviton's [https://amzn.to/3nuIybw 15A &amp;quot;plain&amp;quot; tamper-resistant Decora outlets] and [https://amzn.to/3lKrcXG midsize nylon wall plates] are made in the US. Their website generally has reliable information about country of origin.&lt;br /&gt;
&lt;br /&gt;
== HVAC ==&lt;br /&gt;
* [https://buildersbest.com/where-to-buy/ Builder's Best] for venting solutions. Good luck finding their products anywhere though.&lt;br /&gt;
* See [[Home improvement#HVAC registers that aren't made in China or Vietnam|Home improvement]] for some register options (Shoemaker, Continental)&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Home_improvement&amp;diff=24452</id>
		<title>Home improvement</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Home_improvement&amp;diff=24452"/>
		<updated>2023-06-10T06:32:29Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: /* HVAC registers that aren't made in China or Vietnam */ + continental&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Random tidbits through doing home projects.&lt;br /&gt;
&lt;br /&gt;
* [[Home products made in the USA]]&lt;br /&gt;
&lt;br /&gt;
== Connecting Siemens SPDs to a load center ==&lt;br /&gt;
Siemens SPDs ([https://amzn.to/3ICxhhp FS060/FS60], [https://amzn.to/3lQnBXG FS100], [https://amzn.to/3xyFxZh FS140]) come with an NPT thread on the end, which prevents it from being directly connected into a load center knockout as none of those connectors have NPT thread patterns on them. Siemens support was utterly useless, basically saying &amp;quot;well you should go find what you need&amp;quot;. The solution I ended up arriving at was to use a [https://www.homedepot.com/p/3-4-in-Flexible-Elbow-R6441102/202043366 Cantex 3/4 in. Flexible Elbow], which comes with NPT fittings on both ends, and replace the fitting on one end with an [https://www.homedepot.com/p/3-4-in-90-NMLT-Push-Connector-1-Pack-NMLT907-1/202284600 Arlington 3/4 in. 90° SNAP2IT Non-Metallic Push-On Connector] (also [https://amzn.to/3SayYFY available on Amazon], [http://www.aifittings.com/catalog/liquid-tight/90-degree-snap2it-non-metallic-connectors/NMLT907 Arlington spec page]). If you don't need the 90-degree bend, Arlington makes [http://www.aifittings.com/catalog/liquid-tight/snap2it-non-metallic-connectors/NMLT7 a straight variant] too, which you can get [https://amzn.to/3EoJRy7 on Amazon] or [https://www.homedepot.com/p/SNAP2IT-3-4-in-Non-Metallic-NM-Liquid-Tight-Connector-1-pack-NMLT7-1/202284603 HD] (HD for some reason shows 1/2&amp;quot; in the pictures for the 3/4&amp;quot; product).&lt;br /&gt;
&lt;br /&gt;
The Arlington connectors referenced above are made in the US.&lt;br /&gt;
&lt;br /&gt;
== HVAC registers that aren't made in China or Vietnam ==&lt;br /&gt;
Pretty much every HVAC register at your big box store will come from Vietnam or China. If you're looking for something more local, you have a few options:&lt;br /&gt;
&lt;br /&gt;
* [https://www.imperialgroup.ca Imperial Group's] metal registers are made in Canada. They are trivial to get at [https://www.lowes.ca/product/sidewall-ceiling-registers/imperial-10-in-x-6-in-sideceiling-register-2-way-4871464 Lowe's in Canada], but are a bit more challenging to obtain here in the US. Buying them online is an option, but I had a really hard time ordering these from Amazon and having them arrive without damage. One literally was broken in pieces by the time it was at my doorstep. TrueValue carries some of the fancier floor register models (like the wood and satin metal) in some of their stores in New Jersey, but for some reason not the plain vanilla sidewall ones. Note that some of their products are made in China.&lt;br /&gt;
* [https://decorgrates.com Decor Grates] is another Canadian manufacturer, who appears to make all of their products in Canada, unlike Imperial. However, their [https://amzn.to/3YKOs5R wood floor register] did not look as polished to my eyes and had a very flimsy damper mechanism. Their site is also a giant mess, with &amp;quot;No products were found matching your selection&amp;quot; regularly showing up while navigating it.&lt;br /&gt;
* [https://www.ameriflowregisters.com/residential-grds/sidewall-ceiling-registers-grilles AmeriFlow], aka [https://www.hartandcooley.com/grilles-registers-and-diffusers-grd/residential-grds/sidewall-ceiling-register-grilles Hart &amp;amp; Cooley], makes registers in Mexico and can be found in TrueValue stores as well as e.g. [https://www.supplyhouse.com SupplyHouse]. They seem to be the only ones that make registers that are [https://www.hartandcooley.com/products/681-a681/steel-aluminum-1-way-register-ms-damper-1-2-fin-spacing uni-directional], which is unfortunate as it makes no sense to install a two-way (or straight) register at a vent that's in the corner of a room.&lt;br /&gt;
* [https://www.shoemakermfg.com Shoemaker Manufacturing] appear to be the only manufacturer of registers in the US. They are impossible to find in brick and mortar stores (except in Washington?). Online you can find them on some websites with absolutely astronomical prices and unrealistic return policies. I did end up ordering [https://amzn.to/3kbF6RK one register] on Amazon (and took the hit for return shipping) just to see what it looked like, but the styling didn't really work in a residential setting. The spacing of the fins was also too wide.&lt;br /&gt;
* [https://www.continentalindustries.com Continental] makes registers in the US, though finding them in stores is a challenge as well. They also make one-way registers. [http://www.hepsales.com HEP Sales] quoted a price of $50.35 for 21RW1006 if buying together with something that they stock.&lt;br /&gt;
&lt;br /&gt;
== Pulling dryer terminal block screws out of Samsung dryers ==&lt;br /&gt;
I had the pleasure of dropping not one but two terminal screws in our electric Samsung dryer &amp;quot;into&amp;quot; the dryer. Unlike other manufacturers, Samsung makes the housing of the dryer completely enclosed, so you can't simply &amp;quot;roll&amp;quot; the screw to the front like with other dryers and then just pull it out. There is, however, a way to get them out without fully disassembling the thing. Ironically, it relies on another questionable design decision — leveling legs that come all the way out.&lt;br /&gt;
&lt;br /&gt;
The dryer's leveling legs have two curious features — they are made entirely out of plastic (so excessive force will crack or break them) and they can be completely removed from the dryer if you raise them high enough. This latter property allows us to use the holes to fish out the screws.&lt;br /&gt;
&lt;br /&gt;
Tilt the dryer to the side and back to make sure that your fallen screw is in the rear left corner if looking at the front of the dryer. Then, slightly tilt up the dryer at the rear left corner and use a very strong magnet to reach through the hole and grab the screw. Depending on how strong your magnet is, you might need to reach in with your finger first to bring the screw a little closer to the hole.&lt;br /&gt;
&lt;br /&gt;
A final note: if the dryer is mounted on top of the matching pedestal, you will need to screw the legs onto the pedestal when tilting to get the screw into the corner and then unscrew them when tilting to get the screw out.&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Home_products_made_in_the_USA&amp;diff=24451</id>
		<title>Home products made in the USA</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Home_products_made_in_the_USA&amp;diff=24451"/>
		<updated>2023-03-30T03:13:02Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: sections&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Plumbing ==&lt;br /&gt;
* Most '''Keeney''' plastic tubular sold at Lowe's is made in the US. It is PVC.&lt;br /&gt;
* Home Depot will randomly have '''Oatey''' PP tubular at some locations. For whatever reason, it comes in generic-looking packaging with black and white markings instead of normal-looking branded packaging.&lt;br /&gt;
* Some '''PlumbPak''' plastic tubular (PP) sold on Amazon is made in the US as well, but the product pages can't be relied on for determining this.&lt;br /&gt;
&lt;br /&gt;
== Fasteners ==&lt;br /&gt;
* SPAX screws are made in the US or Germany and sold at both HD and Lowe's. Lowe's tends to have lower prices though their boxes don't include the screw bit in them.&lt;br /&gt;
&lt;br /&gt;
== Electrical ==&lt;br /&gt;
* [https://mulberrymetal.com Mulberry] ''metal'' products are generally made in the US. A limited assortment of their white painted wall plates are sold at HD, but beyond that, you'll have to go to a local electric supply store to find them.&lt;br /&gt;
* Leviton's [https://amzn.to/3nuIybw 15A &amp;quot;plain&amp;quot; tamper-resistant Decora outlets] and [https://amzn.to/3lKrcXG midsize nylon wall plates] are made in the US. Their website generally has reliable information about country of origin.&lt;br /&gt;
&lt;br /&gt;
== HVAC ==&lt;br /&gt;
* [https://buildersbest.com/where-to-buy/ Builder's Best] for venting solutions. Good luck finding their products anywhere though.&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Home_products_made_in_the_USA&amp;diff=24450</id>
		<title>Home products made in the USA</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Home_products_made_in_the_USA&amp;diff=24450"/>
		<updated>2023-03-30T02:53:57Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Created page with &amp;quot;== Plumbing ==  * Most '''Keeney''' plastic tubular sold at Lowe's is made in the US. It is PVC. * Home Depot will randomly have '''Oatey''' PP tubular at some locations. For...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Plumbing ==&lt;br /&gt;
&lt;br /&gt;
* Most '''Keeney''' plastic tubular sold at Lowe's is made in the US. It is PVC.&lt;br /&gt;
* Home Depot will randomly have '''Oatey''' PP tubular at some locations. For whatever reason, it comes in generic-looking packaging with black and white markings instead of normal-looking branded packaging.&lt;br /&gt;
* Some '''PlumbPak''' plastic tubular (PP) sold on Amazon is made in the US as well, but the product pages can't be relied on for determining this.&lt;br /&gt;
* [https://mulberrymetal.com Mulberry] ''metal'' products are generally made in the US. A limited assortment of their white painted wall plates are sold at HD, but beyond that, you'll have to go to a local electric supply store to find them.&lt;br /&gt;
* SPAX screws are made in the US or Germany and sold at both HD and Lowe's. Lowe's tends to have lower prices though their boxes don't include the screw bit in them.&lt;br /&gt;
* Leviton's [https://amzn.to/3nuIybw 15A &amp;quot;plain&amp;quot; tamper-resistant Decora outlets] and [https://amzn.to/3lKrcXG midsize nylon wall plates] are made in the US. Their website generally has reliable information about country of origin.&lt;br /&gt;
* [https://buildersbest.com/where-to-buy/ Builder's Best] for venting solutions. Good luck finding their products anywhere though.&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Home_improvement&amp;diff=24449</id>
		<title>Home improvement</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Home_improvement&amp;diff=24449"/>
		<updated>2023-03-30T02:34:59Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Random tidbits through doing home projects.&lt;br /&gt;
&lt;br /&gt;
* [[Home products made in the USA]]&lt;br /&gt;
&lt;br /&gt;
== Connecting Siemens SPDs to a load center ==&lt;br /&gt;
Siemens SPDs ([https://amzn.to/3ICxhhp FS060/FS60], [https://amzn.to/3lQnBXG FS100], [https://amzn.to/3xyFxZh FS140]) come with an NPT thread on the end, which prevents it from being directly connected into a load center knockout as none of those connectors have NPT thread patterns on them. Siemens support was utterly useless, basically saying &amp;quot;well you should go find what you need&amp;quot;. The solution I ended up arriving at was to use a [https://www.homedepot.com/p/3-4-in-Flexible-Elbow-R6441102/202043366 Cantex 3/4 in. Flexible Elbow], which comes with NPT fittings on both ends, and replace the fitting on one end with an [https://www.homedepot.com/p/3-4-in-90-NMLT-Push-Connector-1-Pack-NMLT907-1/202284600 Arlington 3/4 in. 90° SNAP2IT Non-Metallic Push-On Connector] (also [https://amzn.to/3SayYFY available on Amazon], [http://www.aifittings.com/catalog/liquid-tight/90-degree-snap2it-non-metallic-connectors/NMLT907 Arlington spec page]). If you don't need the 90-degree bend, Arlington makes [http://www.aifittings.com/catalog/liquid-tight/snap2it-non-metallic-connectors/NMLT7 a straight variant] too, which you can get [https://amzn.to/3EoJRy7 on Amazon] or [https://www.homedepot.com/p/SNAP2IT-3-4-in-Non-Metallic-NM-Liquid-Tight-Connector-1-pack-NMLT7-1/202284603 HD] (HD for some reason shows 1/2&amp;quot; in the pictures for the 3/4&amp;quot; product).&lt;br /&gt;
&lt;br /&gt;
The Arlington connectors referenced above are made in the US.&lt;br /&gt;
&lt;br /&gt;
== HVAC registers that aren't made in China or Vietnam ==&lt;br /&gt;
Pretty much every HVAC register at your big box store will come from Vietnam or China. If you're looking for something more local, you have a few options:&lt;br /&gt;
&lt;br /&gt;
* [https://www.imperialgroup.ca Imperial Group's] metal registers are made in Canada. They are trivial to get at [https://www.lowes.ca/product/sidewall-ceiling-registers/imperial-10-in-x-6-in-sideceiling-register-2-way-4871464 Lowe's in Canada], but are a bit more challenging to obtain here in the US. Buying them online is an option, but I had a really hard time ordering these from Amazon and having them arrive without damage. One literally was broken in pieces by the time it was at my doorstep. TrueValue carries some of the fancier floor register models (like the wood and satin metal) in some of their stores in New Jersey, but for some reason not the plain vanilla sidewall ones. Note that some of their products are made in China.&lt;br /&gt;
* [https://decorgrates.com Decor Grates] is another Canadian manufacturer, who appears to make all of their products in Canada, unlike Imperial. However, their [https://amzn.to/3YKOs5R wood floor register] did not look as polished to my eyes and had a very flimsy damper mechanism. Their site is also a giant mess, with &amp;quot;No products were found matching your selection&amp;quot; regularly showing up while navigating it.&lt;br /&gt;
* [https://www.ameriflowregisters.com/residential-grds/sidewall-ceiling-registers-grilles AmeriFlow], aka [https://www.hartandcooley.com/grilles-registers-and-diffusers-grd/residential-grds/sidewall-ceiling-register-grilles Hart &amp;amp; Cooley], makes registers in Mexico and can be found in TrueValue stores as well as e.g. [https://www.supplyhouse.com SupplyHouse]. They seem to be the only ones that make registers that are [https://www.hartandcooley.com/products/681-a681/steel-aluminum-1-way-register-ms-damper-1-2-fin-spacing uni-directional], which is unfortunate as it makes no sense to install a two-way (or straight) register at a vent that's in the corner of a room.&lt;br /&gt;
* [https://www.shoemakermfg.com Shoemaker Manufacturing] appear to be the only manufacturer of registers in the US. They are impossible to find in brick and mortar stores (except in Washington?). Online you can find them on some websites with absolutely astronomical prices and unrealistic return policies. I did end up ordering [https://amzn.to/3kbF6RK one register] on Amazon (and took the hit for return shipping) just to see what it looked like, but the styling didn't really work in a residential setting. The spacing of the fins was also too wide.&lt;br /&gt;
&lt;br /&gt;
== Pulling dryer terminal block screws out of Samsung dryers ==&lt;br /&gt;
I had the pleasure of dropping not one but two terminal screws in our electric Samsung dryer &amp;quot;into&amp;quot; the dryer. Unlike other manufacturers, Samsung makes the housing of the dryer completely enclosed, so you can't simply &amp;quot;roll&amp;quot; the screw to the front like with other dryers and then just pull it out. There is, however, a way to get them out without fully disassembling the thing. Ironically, it relies on another questionable design decision — leveling legs that come all the way out.&lt;br /&gt;
&lt;br /&gt;
The dryer's leveling legs have two curious features — they are made entirely out of plastic (so excessive force will crack or break them) and they can be completely removed from the dryer if you raise them high enough. This latter property allows us to use the holes to fish out the screws.&lt;br /&gt;
&lt;br /&gt;
Tilt the dryer to the side and back to make sure that your fallen screw is in the rear left corner if looking at the front of the dryer. Then, slightly tilt up the dryer at the rear left corner and use a very strong magnet to reach through the hole and grab the screw. Depending on how strong your magnet is, you might need to reach in with your finger first to bring the screw a little closer to the hole.&lt;br /&gt;
&lt;br /&gt;
A final note: if the dryer is mounted on top of the matching pedestal, you will need to screw the legs onto the pedestal when tilting to get the screw into the corner and then unscrew them when tilting to get the screw out.&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Home_improvement&amp;diff=24448</id>
		<title>Home improvement</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Home_improvement&amp;diff=24448"/>
		<updated>2023-03-21T15:49:11Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: +dryer screws&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Random tidbits through doing home projects.&lt;br /&gt;
&lt;br /&gt;
== Connecting Siemens SPDs to a load center ==&lt;br /&gt;
Siemens SPDs ([https://amzn.to/3ICxhhp FS060/FS60], [https://amzn.to/3lQnBXG FS100], [https://amzn.to/3xyFxZh FS140]) come with an NPT thread on the end, which prevents it from being directly connected into a load center knockout as none of those connectors have NPT thread patterns on them. Siemens support was utterly useless, basically saying &amp;quot;well you should go find what you need&amp;quot;. The solution I ended up arriving at was to use a [https://www.homedepot.com/p/3-4-in-Flexible-Elbow-R6441102/202043366 Cantex 3/4 in. Flexible Elbow], which comes with NPT fittings on both ends, and replace the fitting on one end with an [https://www.homedepot.com/p/3-4-in-90-NMLT-Push-Connector-1-Pack-NMLT907-1/202284600 Arlington 3/4 in. 90° SNAP2IT Non-Metallic Push-On Connector] (also [https://amzn.to/3SayYFY available on Amazon], [http://www.aifittings.com/catalog/liquid-tight/90-degree-snap2it-non-metallic-connectors/NMLT907 Arlington spec page]). If you don't need the 90-degree bend, Arlington makes [http://www.aifittings.com/catalog/liquid-tight/snap2it-non-metallic-connectors/NMLT7 a straight variant] too, which you can get [https://amzn.to/3EoJRy7 on Amazon] or [https://www.homedepot.com/p/SNAP2IT-3-4-in-Non-Metallic-NM-Liquid-Tight-Connector-1-pack-NMLT7-1/202284603 HD] (HD for some reason shows 1/2&amp;quot; in the pictures for the 3/4&amp;quot; product).&lt;br /&gt;
&lt;br /&gt;
The Arlington connectors referenced above are made in the US.&lt;br /&gt;
&lt;br /&gt;
== HVAC registers that aren't made in China or Vietnam ==&lt;br /&gt;
Pretty much every HVAC register at your big box store will come from Vietnam or China. If you're looking for something more local, you have a few options:&lt;br /&gt;
&lt;br /&gt;
* [https://www.imperialgroup.ca Imperial Group's] metal registers are made in Canada. They are trivial to get at [https://www.lowes.ca/product/sidewall-ceiling-registers/imperial-10-in-x-6-in-sideceiling-register-2-way-4871464 Lowe's in Canada], but are a bit more challenging to obtain here in the US. Buying them online is an option, but I had a really hard time ordering these from Amazon and having them arrive without damage. One literally was broken in pieces by the time it was at my doorstep. TrueValue carries some of the fancier floor register models (like the wood and satin metal) in some of their stores in New Jersey, but for some reason not the plain vanilla sidewall ones. Note that some of their products are made in China.&lt;br /&gt;
* [https://decorgrates.com Decor Grates] is another Canadian manufacturer, who appears to make all of their products in Canada, unlike Imperial. However, their [https://amzn.to/3YKOs5R wood floor register] did not look as polished to my eyes and had a very flimsy damper mechanism. Their site is also a giant mess, with &amp;quot;No products were found matching your selection&amp;quot; regularly showing up while navigating it.&lt;br /&gt;
* [https://www.ameriflowregisters.com/residential-grds/sidewall-ceiling-registers-grilles AmeriFlow], aka [https://www.hartandcooley.com/grilles-registers-and-diffusers-grd/residential-grds/sidewall-ceiling-register-grilles Hart &amp;amp; Cooley], makes registers in Mexico and can be found in TrueValue stores as well as e.g. [https://www.supplyhouse.com SupplyHouse]. They seem to be the only ones that make registers that are [https://www.hartandcooley.com/products/681-a681/steel-aluminum-1-way-register-ms-damper-1-2-fin-spacing uni-directional], which is unfortunate as it makes no sense to install a two-way (or straight) register at a vent that's in the corner of a room.&lt;br /&gt;
* [https://www.shoemakermfg.com Shoemaker Manufacturing] appear to be the only manufacturer of registers in the US. They are impossible to find in brick and mortar stores (except in Washington?). Online you can find them on some websites with absolutely astronomical prices and unrealistic return policies. I did end up ordering [https://amzn.to/3kbF6RK one register] on Amazon (and took the hit for return shipping) just to see what it looked like, but the styling didn't really work in a residential setting. The spacing of the fins was also too wide.&lt;br /&gt;
&lt;br /&gt;
== Pulling dryer terminal block screws out of Samsung dryers ==&lt;br /&gt;
I had the pleasure of dropping not one but two terminal screws in our electric Samsung dryer &amp;quot;into&amp;quot; the dryer. Unlike other manufacturers, Samsung makes the housing of the dryer completely enclosed, so you can't simply &amp;quot;roll&amp;quot; the screw to the front like with other dryers and then just pull it out. There is, however, a way to get them out without fully disassembling the thing. Ironically, it relies on another questionable design decision — leveling legs that come all the way out.&lt;br /&gt;
&lt;br /&gt;
The dryer's leveling legs have two curious features — they are made entirely out of plastic (so excessive force will crack or break them) and they can be completely removed from the dryer if you raise them high enough. This latter property allows us to use the holes to fish out the screws.&lt;br /&gt;
&lt;br /&gt;
Tilt the dryer to the side and back to make sure that your fallen screw is in the rear left corner if looking at the front of the dryer. Then, slightly tilt up the dryer at the rear left corner and use a very strong magnet to reach through the hole and grab the screw. Depending on how strong your magnet is, you might need to reach in with your finger first to bring the screw a little closer to the hole.&lt;br /&gt;
&lt;br /&gt;
A final note: if the dryer is mounted on top of the matching pedestal, you will need to screw the legs onto the pedestal when tilting to get the screw into the corner and then unscrew them when tilting to get the screw out.&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Priceline_Rewards_credit_cards&amp;diff=24447</id>
		<title>Priceline Rewards credit cards</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Priceline_Rewards_credit_cards&amp;diff=24447"/>
		<updated>2023-03-04T04:06:16Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: a few more redemption rate maths&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Barclays issued a priceline rewards credit card at least as far back as 2017, though it's impossible to find info on it now. Its earnings structure was quite simple:&lt;br /&gt;
&lt;br /&gt;
* 5 points per dollar on Priceline purchases&lt;br /&gt;
* 1 point per dollar on everything else&lt;br /&gt;
&lt;br /&gt;
Things got more interesting, however, once you started to redeem those points, because the redemption values were ''also'' different between priceline purchases vs. everything else:&lt;br /&gt;
&lt;br /&gt;
* 1.5% dollar value for points redeemed against priceline purchases&lt;br /&gt;
* 1% dollar value for points redeemed against all other purchases&lt;br /&gt;
* 10% point redemption refund on all redemptions&lt;br /&gt;
&lt;br /&gt;
This meant that the effective cash back rate on priceline purchases when redeemed against priceline purchases was 5 × 1.5 / 0.9 = 8.33%. If that sounds too good to be true, just do the math on a hypothetical $1000 priceline purchase: you earn 5000 points, which corresponds to a $75 redemption against that purchase, but when you go to use the redemption, only 4500 points are used. The remaining 500 points are worth $7.50 when redeemed against a pricelline purchase, so you effectively get $82.50 worth of rewards against a $1000 purchase (though those points would only &amp;quot;cost&amp;quot; 450, since you'd get another 10% back on that redemption, and on and on).&lt;br /&gt;
&lt;br /&gt;
Note that you could also &amp;quot;cross-redeem&amp;quot;, i.e. take points from a regular purchase and redeem them against a priceline purchase and vice versa. This gave you an effective rate of 1.67% for regular purchases redeemed against priceline ones and 5.5% for priceline purchases redeemed against regular ones.&lt;br /&gt;
&lt;br /&gt;
Someone at Barclays probably eventually realized this was too good to be true too, and so in 2022 they introduced the new Priceline VIP Rewards credit card. The earning structure, on paper, got better, because in addition to the earnings with the original card, gas and restaurant purchases would now earn 2 points per dollar spent. They added a rather dubious VIP Gold status as a &amp;quot;perk&amp;quot;, as well as reimbursement of TSA PreCheck or Global Entry application fees once your annual spend exceeds $10,000. But the all of the redemption bonuses went away — all purchases now redeemed at 1% and there was no redemption refund. So even non-priceline purchases got a worse redemption rate on this card than the old one!&lt;br /&gt;
&lt;br /&gt;
Of course, the old card is no longer available. However, the reason this matters is because for those who still have the old card, Barclays will tempt you to &amp;quot;upgrade&amp;quot; with this brilliant wording:&lt;br /&gt;
&lt;br /&gt;
{{quote|Update your account to the Priceline VIP Rewards™ Visa® Card and enjoy extraordinary new benefits and services.}}&lt;br /&gt;
&lt;br /&gt;
The touted &amp;quot;benefits&amp;quot; are as follows:&lt;br /&gt;
&lt;br /&gt;
* Reduction of effective priceline redemption rate by 40%&lt;br /&gt;
* Reduction of effective other purchase redemption rate by 10%&lt;br /&gt;
* Increase of effective redemption rate for gas and restaurant purchases by 80%&lt;br /&gt;
* An additional 1% discount for the GE fee once every 5 years (since GE costs $100 and you have to put at least $10,000 of spend on the card to get it)&lt;br /&gt;
&lt;br /&gt;
Given the huge devaluation in priceline redemptions and the multitude of other cards that give a straight 2% cash back on all purchases, there is absolutely no reason for anyone with the older card to &amp;quot;upgrade&amp;quot; to the new one.&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Priceline_Rewards_credit_cards&amp;diff=24446</id>
		<title>Priceline Rewards credit cards</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Priceline_Rewards_credit_cards&amp;diff=24446"/>
		<updated>2023-03-04T04:02:04Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Barclays issued a priceline rewards credit card at least as far back as 2017, though it's impossible to find info on it now. Its earnings structure was quite simple:&lt;br /&gt;
&lt;br /&gt;
* 5 points per dollar on Priceline purchases&lt;br /&gt;
* 1 point per dollar on everything else&lt;br /&gt;
&lt;br /&gt;
Things got more interesting, however, once you started to redeem those points, because the redemption values were ''also'' different between priceline purchases vs. everything else:&lt;br /&gt;
&lt;br /&gt;
* 1.5% dollar value for points redeemed against priceline purchases&lt;br /&gt;
* 1% dollar value for points redeemed against all other purchases&lt;br /&gt;
* 10% point redemption refund on all redemptions&lt;br /&gt;
&lt;br /&gt;
This meant that the effective cash back rate on priceline purchases when redeemed against priceline purchases was 5 × 1.5 / 0.9 = 8.33%. If that sounds too good to be true, just do the math on a hypothetical $1000 priceline purchase: you earn 5000 points, which corresponds to a $75 redemption against that purchase, but when you go to use the redemption, only 4500 points are used. The remaining 500 points are worth $7.50 when redeemed against a pricelline purchase, so you effectively get $82.50 worth of rewards against a $1000 purchase (though those points would only &amp;quot;cost&amp;quot; 450, since you'd get another 10% back on that redemption, and on and on).&lt;br /&gt;
&lt;br /&gt;
Someone at Barclays probably eventually realized this too, and so in 2022 they introduced the new Priceline VIP Rewards credit card. The earning structure, on paper, got better, because in addition to the earnings with the original card, gas and restaurant purchases would now earn 2 points per dollar spent. They added a rather dubious VIP Gold status as a &amp;quot;perk&amp;quot;, as well as reimbursement of TSA PreCheck or Global Entry application fees once your annual spend exceeds $10,000. But the all of the redemption bonuses went away — all purchases now redeemed at 1% and there was no redemption refund. So even non-priceline purchases got a worse redemption rate on this card than the old one!&lt;br /&gt;
&lt;br /&gt;
Of course, the old card is no longer available. However, the reason this matters is because for those who still have the old card, Barclays will tempt you to &amp;quot;upgrade&amp;quot; with this brilliant wording:&lt;br /&gt;
&lt;br /&gt;
{{quote|Update your account to the Priceline VIP Rewards™ Visa® Card and enjoy extraordinary new benefits and services.}}&lt;br /&gt;
&lt;br /&gt;
The touted &amp;quot;benefits&amp;quot; are as follows:&lt;br /&gt;
&lt;br /&gt;
* Reduction of effective priceline redemption rate by 40%&lt;br /&gt;
* Reduction of effective other purchase redemption rate by 10%&lt;br /&gt;
* Increase of effective redemption rate for gas and restaurant purchases by 80%&lt;br /&gt;
* An additional 1% discount for the GE fee once every 5 years (since GE costs $100 and you have to put at least $10,000 of spend on the card to get it)&lt;br /&gt;
&lt;br /&gt;
Given the huge devaluation in priceline redemptions and the multitude of other cards that give a straight 2% cash back on all purchases, there is absolutely no reason for anyone with the older card to &amp;quot;upgrade&amp;quot; to the new one.&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Priceline_Rewards_credit_cards&amp;diff=24445</id>
		<title>Priceline Rewards credit cards</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Priceline_Rewards_credit_cards&amp;diff=24445"/>
		<updated>2023-03-04T04:01:06Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: formatting&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Barclays issued a priceline rewards credit card at least as far back as 2017, though it's impossible to find info on it now. Its earnings structure was quite simple:&lt;br /&gt;
&lt;br /&gt;
* 5 points per dollar on Priceline purchases&lt;br /&gt;
* 1 point per dollar on everything else&lt;br /&gt;
&lt;br /&gt;
Things got more interesting, however, once you started to redeem those points, because the redemption values were ''also'' different between priceline purchases vs. everything else:&lt;br /&gt;
&lt;br /&gt;
* 1.5% dollar value for points redeemed against priceline purchases&lt;br /&gt;
* 1% dollar value for points redeemed against all other purchases&lt;br /&gt;
* 10% point redemption refund on all redemptions&lt;br /&gt;
&lt;br /&gt;
This meant that the effective cash back rate on priceline purchases when redeemed against priceline purchases was 5 × 1.5 / 0.9 = 8.33%. If that sounds too good to be true, just do the math on a hypothetical $1000 priceline purchase: you earn 5000 points, which corresponds to a $75 redemption against that purchase, but when you go to use the redemption, only 4500 points are used. The remaining 500 points are worth $7.50 when redeemed against a pricelline purchase, so you effectively get $82.50 worth of rewards against a $1000 purchase.&lt;br /&gt;
&lt;br /&gt;
Someone at Barclays probably eventually realized this too, and so in 2022 they introduced the new Priceline VIP Rewards credit card. The earning structure, on paper, got better, because in addition to the earnings with the original card, gas and restaurant purchases would now earn 2 points per dollar spent. They added a rather dubious VIP Gold status as a &amp;quot;perk&amp;quot;, as well as reimbursement of TSA PreCheck or Global Entry application fees once your annual spend exceeds $10,000. But the all of the redemption bonuses went away — all purchases now redeemed at 1% and there was no redemption refund. So even non-priceline purchases got a worse redemption rate on this card than the old one!&lt;br /&gt;
&lt;br /&gt;
Of course, the old card is no longer available. However, the reason this matters is because for those who still have the old card, Barclays will tempt you to &amp;quot;upgrade&amp;quot; with this brilliant wording:&lt;br /&gt;
&lt;br /&gt;
{{quote|Update your account to the Priceline VIP Rewards™ Visa® Card and enjoy extraordinary new benefits and services.}}&lt;br /&gt;
&lt;br /&gt;
The touted &amp;quot;benefits&amp;quot; are as follows:&lt;br /&gt;
&lt;br /&gt;
* Reduction of effective priceline redemption rate by 40%&lt;br /&gt;
* Reduction of effective other purchase redemption rate by 10%&lt;br /&gt;
* Increase of effective redemption rate for gas and restaurant purchases by 80%&lt;br /&gt;
* An additional 1% discount for the GE fee once every 5 years (since GE costs $100 and you have to put at least $10,000 of spend on the card to get it)&lt;br /&gt;
&lt;br /&gt;
Given the huge devaluation in priceline redemptions and the multitude of other cards that give a straight 2% cash back on all purchases, there is absolutely no reason for anyone with the older card to &amp;quot;upgrade&amp;quot; to the new one.&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Priceline_Rewards_credit_cards&amp;diff=24444</id>
		<title>Priceline Rewards credit cards</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Priceline_Rewards_credit_cards&amp;diff=24444"/>
		<updated>2023-03-04T04:00:35Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Created page with &amp;quot;Barclays issued a priceline rewards credit card at least as far back as 2017, though it's impossible to find info on it now. Its earnings structure was quite simple:  * 5 poin...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Barclays issued a priceline rewards credit card at least as far back as 2017, though it's impossible to find info on it now. Its earnings structure was quite simple:&lt;br /&gt;
&lt;br /&gt;
* 5 points per dollar on Priceline purchases&lt;br /&gt;
* 1 point per dollar on everything else&lt;br /&gt;
&lt;br /&gt;
Things got more interesting, however, once you started to redeem those points, because the redemption values were 'also' different between priceline purchases vs. everything else:&lt;br /&gt;
&lt;br /&gt;
* 1.5% dollar value for points redeemed against priceline purchases&lt;br /&gt;
* 1% dollar value for points redeemed against all other purchases&lt;br /&gt;
* 10% point redemption refund on all redemptions&lt;br /&gt;
&lt;br /&gt;
This meant that the effective cash back rate on priceline purchases when redeemed against priceline purchases was 5 × 1.5 / 0.9 = 8.33%. If that sounds too good to be true, just do the math on a hypothetical $1000 priceline purchase: you earn 5000 points, which corresponds to a $75 redemption against that purchase, but when you go to use the redemption, only 4500 points are used. The remaining 500 points are worth $7.50 when redeemed against a pricelline purchase, so you effectively get $82.50 worth of rewards against a $1000 purchase.&lt;br /&gt;
&lt;br /&gt;
Someone at Barclays probably eventually realized this too, and so in 2022 they introduced the new Priceline VIP Rewards credit card. The earning structure, on paper, got better, because in addition to the earnings with the original card, gas and restaurant purchases would now earn 2 points per dollar spent. They added a rather dubious VIP Gold status as a &amp;quot;perk&amp;quot;, as well as reimbursement of TSA PreCheck or Global Entry application fees once your annual spend exceeds $10,000. But the all of the redemption bonuses went away — all purchases now redeemed at 1% and there was no redemption refund. So even non-priceline purchases got a worse redemption rate on this card than the old one!&lt;br /&gt;
&lt;br /&gt;
Of course, the old card is no longer available. However, the reason this matters is because for those who still have the old card, Barclays will tempt you to &amp;quot;upgrade&amp;quot; with this brilliant wording:&lt;br /&gt;
&lt;br /&gt;
{{quote|Update your account to the Priceline VIP Rewards™ Visa® Card and enjoy extraordinary new benefits and services.}}&lt;br /&gt;
&lt;br /&gt;
The touted &amp;quot;benefits&amp;quot; are as follows:&lt;br /&gt;
&lt;br /&gt;
* Reduction of effective priceline redemption rate by 40%&lt;br /&gt;
* Reduction of effective other purchase redemption rate by 10%&lt;br /&gt;
* Increase of effective redemption rate for gas and restaurant purchases by 80%&lt;br /&gt;
* An additional 1% discount for the GE fee once every 5 years (since GE costs $100 and you have to put at least $10,000 of spend on the card to get it)&lt;br /&gt;
&lt;br /&gt;
Given the huge devaluation in priceline redemptions and the multitude of other cards that give a straight 2% cash back on all purchases, there is absolutely no reason for anyone with the older card to &amp;quot;upgrade&amp;quot; to the new one.&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=lensowiki:Community_Portal&amp;diff=24443</id>
		<title>lensowiki:Community Portal</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=lensowiki:Community_Portal&amp;diff=24443"/>
		<updated>2023-03-04T03:31:23Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: /* Personal records */ +priceline&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Welcome to the '''Community Portal'''! For more information about the lensowiki project, see the [[lensowiki:About|About]] page.&lt;br /&gt;
&lt;br /&gt;
New articles will be announced and listed here, listed by subject.&lt;br /&gt;
&lt;br /&gt;
==Computer Science/IT==&lt;br /&gt;
*[[CS]] ''list of various CS projects, including personal projects and classwork''&lt;br /&gt;
*[[DC|DC++]] ''config instructions for Cal hub''&lt;br /&gt;
*[[lensowiki:Installation caveats|Installation caveats]] ''details the problems inherent in a MediaWiki installation with a UTF-8 encoding for the database tables and functional workarounds''&lt;br /&gt;
*[[Sony Clie on Mac OS X]] ''provides instructions for syncing Sony Clie handhelds on Mac OS X without Missing Sync''&lt;br /&gt;
&lt;br /&gt;
==History==&lt;br /&gt;
*[[History of Alsace and Lorraine]] ''in French''&lt;br /&gt;
&lt;br /&gt;
==Home Improvement==&lt;br /&gt;
*[[Home improvement]]&lt;br /&gt;
&lt;br /&gt;
==Personal records==&lt;br /&gt;
*[[Caltrain]] ''a nasty incident on Caltrain in which I was forced off a train after paying my fare with Translink''&lt;br /&gt;
*[[Photo shoots]] ''photo-shooting locations and notes''&lt;br /&gt;
*[[Swimming]] ''includes swimming workouts''&lt;br /&gt;
*[[Class schedule]] ''class schedules for past and current semesters''&lt;br /&gt;
*[[Academic plans]] ''4-year plans for graduation''&lt;br /&gt;
*[[Priceline Rewards credit cards]] ''a comparison that exists nowhere else on the internet''&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=FMenu/flash&amp;diff=24442</id>
		<title>FMenu/flash</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=FMenu/flash&amp;diff=24442"/>
		<updated>2023-02-21T09:53:28Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;margin: auto 5em; border: red medium solid; padding: 0.5em; background: #f9f9f9;&amp;quot;&amp;gt;&lt;br /&gt;
''FMenu version 3.1 was released on January 17, 2010 and includes stability improvements, UI changes to keep up with site updates, and full Snow Leopard compatibility. Note that there are now separate downloads for users of 10.4 and everyone else.''&lt;br /&gt;
&lt;br /&gt;
''It is now 2023 and Facebook's API has changed significantly such that this app no longer works. The way that people use Facebook has changed dramatically as well. Growl no longer exists. Perhaps one day this app will come back — or not.''&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=FMenu&amp;diff=24441</id>
		<title>FMenu</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=FMenu&amp;diff=24441"/>
		<updated>2023-02-21T09:52:09Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{/flash}}&lt;br /&gt;
[[Image:FMenu-main.png|thumb|400px|Screenshot of FMenu]]&lt;br /&gt;
[[Image:Fmenu-prefs.png|thumb|400px|Screenshot of FMenu prefs window]]&lt;br /&gt;
'''FMenu''' was a program for [[w:Mac OS X|Mac OS X]] and [[w:Facebook|Facebook]] that sits in the menu bar (near the clock) and provides notifications about various events. In addition, it provides a menu to easily access common Facebook pages and keeps a count of your messages, pokes, events, friend requests, wall posts, and photo comments. It also features a &amp;quot;Quicklaunch&amp;quot; box which gives you immediate access to your friends' profiles, groups, and events, as well as Facebook searches (type a phrase and press enter). Notifications are issued using [[w:Growl|Growl]] and can be customized to the user's liking (including turning on/off and customizing display style). They are:&lt;br /&gt;
*A friend updated his profile&lt;br /&gt;
*A friend changed his status&lt;br /&gt;
*A friend wrote a new note&lt;br /&gt;
*Someone wrote on your wall&lt;br /&gt;
*You have new messages&lt;br /&gt;
*You have new pokes&lt;br /&gt;
*You have new friend requests&lt;br /&gt;
FMenu checks for updates by default every 7 seconds (or at whatever interval you set), but checks for each kind of notification (friend details, friend requests, wall, messages/pokes, events) separately. Consequently each particular type of notification is refreshed once every 42 seconds.&lt;br /&gt;
&lt;br /&gt;
'''Please note:''' this application will work with most of your friends. However, if you are not getting notifications for some friends, it probably means that they have opted out of releasing their info to applications using the Facebook API. Tell your friends to go to [http://www.facebook.com/settings/?tab=privacy&amp;amp;section=applications&amp;amp;field=friends_share Facebook's Applications &amp;amp; Websites privacy settings] and make sure that the checkbox labeled ''Status updates'' is '''checked'''. Otherwise, FMenu has absolutely no way of retrieving that user's profile.&lt;br /&gt;
&lt;br /&gt;
==Download==&lt;br /&gt;
{{/buttons}}&lt;br /&gt;
The latest version is {{/version}}. It is a [[w:Universal Binary|Universal Binary]] and requires Mac OS X 10.4 or better. Note that since version 3.1, there are separate downloads for users of Mac OS X 10.4 and 10.5 and above, due to 64-bit loading issues with Growl. However, there is no functional difference between the versions. The 10.5 and above binary is 64-bit and fully compatible with Snow Leopard.&lt;br /&gt;
*FMenu for users of [{{/latestversion/10.4}} 10.4 only] and [{{/latestversion/10.5}} 10.5 and above] who ''already have Growl installed on their system'' (.zip file)&lt;br /&gt;
*[{{/3.0/Growl}} FMenu for all other users] – if you do not have Growl installed, FMenu will prompt you to install it automatically with no additional downloads required (.zip file). Note that this is version 3.0; after installation of Growl, check for updates in the menu to update to the latest version.&lt;br /&gt;
FMenu is released under the [http://www.gnu.org/licenses/gpl.html GNU General Public License]. Source code can be found inside the application package by going to &amp;lt;tt&amp;gt;FMenu.app/Contents/Resources/Source&amp;lt;/tt&amp;gt; or checked out using [[w:Subversion (software)|SVN]] [http://sourceforge.net/svn/?group_id=188286 from SourceForge].&lt;br /&gt;
&lt;br /&gt;
Older versions can be obtained below; however, they are unsupported, generally inferior, and only provided for archival purposes.&lt;br /&gt;
&lt;br /&gt;
==Installation==&lt;br /&gt;
Simply download the appropriate file above, then double-click it. FMenu.app will appear in the same folder as the .zip file you just downloaded. Move FMenu.app to your Applications and double-click it to open. You might also want to add it to your startup items by going to System Preferences→Accounts, selecting your account on the left, then clicking on the '''Login items''' tab. Click the '''+''' button and choose FMenu from the window that appears.&lt;br /&gt;
&lt;br /&gt;
As of version 2.5, you can have your Facebook credentials saved by checking the according checkbox on the login page. Note that FMenu does not store your actual password and that this procedure does '''not''' compromise the security of your Facebook account in any way.&lt;br /&gt;
&lt;br /&gt;
==Acknowledgments==&lt;br /&gt;
This application completely relies on [http://pointlesscrap.net/mkabefook/ MKAbeFook framework] written by Mike Kinney to communicate with the [http://developers.facebook.com/documentation.php Facebook API]. In addition, the first version of the app was written by Logan Rockmore of [http://www.burgundylogan.com Logan Design].&lt;br /&gt;
&lt;br /&gt;
==Known issues==&lt;br /&gt;
*If you put your computer to sleep for an extended period of time, FMenu will obviously give a large number of notifications that happened during the time that your computer was turned off the first time it updates. Make sure that the number of &amp;quot;sticky&amp;quot; notifications is not very high, because otherwise you will spend a lot of time dismissing all of them (Workaround: Alt-click on any growl notifications's close (X) button to dismiss all the messages on-screen).&lt;br /&gt;
*If you remove a friend while FMenu is running (or a friend disables their account, etc), you will get a notice saying they changed their profile and published a note.&lt;br /&gt;
*If you change your Facebook password, you will stop receiving notifications. Choose Log out… from the menu and then log back in to resume receiving notifications.&lt;br /&gt;
&lt;br /&gt;
There is also a [[/FAQ|FAQ]] of common questions and problems. If you have other questions or problems, please follow the instructions on the [[Talk:{{PAGENAME}}|discussion page]].&lt;br /&gt;
&lt;br /&gt;
==Version history==&lt;br /&gt;
{{/changelog}}&lt;br /&gt;
&lt;br /&gt;
{{cs projects}}&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Class_schedule&amp;diff=24440</id>
		<title>Class schedule</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Class_schedule&amp;diff=24440"/>
		<updated>2023-02-21T08:11:08Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: /* Spring 08 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Class schedules, in their various iterations, will be placed here, in reverse chronological order (last semester first).&lt;br /&gt;
To put a pretty table taken from [http://www.ocf.berkeley.edu/~amanb/makeSched/ Aman's schedule maker] here, copy the HTML and then perform the following search/replace functions in SubEthaEdit:&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;&amp;lt;a\sclass=subtle\stitle=&amp;quot;CCN:\s\d\d\d\d\d\&amp;quot;\shref=\&amp;quot;javascript:ccn\(\'\d\d\d\d\d\'\)&amp;quot;&amp;gt;&amp;lt;/nowiki&amp;gt; ''[[w:regexp|regexp]]''&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;&amp;lt;a\sclass=del\shref=&amp;quot;javascript:del\(\'\d\d\d\d\d\'\)&amp;quot;&amp;gt;&amp;lt;/nowiki&amp;gt; ''[[w:regexp|regexp]]''&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;&amp;lt;/A&amp;gt;&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;&amp;lt;img border=0 src=&amp;quot;../x.gif&amp;quot;&amp;gt;&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Spring 08==&lt;br /&gt;
 CS:160-LEC TuTh 330-5P  306 SODA CCN=26479&lt;br /&gt;
 CS:160-DIS-:102 Tu 2-3P  310 SODA CCN=26485&lt;br /&gt;
 STAT:131A-LEC TuTh 1230-2P  155 KROEBER CCN=87444&lt;br /&gt;
 STAT:131A-LAB-:101 MW 11-12P  332 EVANS CCN=87447&lt;br /&gt;
 SLAL:46-LEC MWF 12-1P  174 BARROWS CCN=79754&lt;br /&gt;
 CAEE:155-LEC TuTh 10-11A  3106 ETCHEVERRY CCN=14044&lt;br /&gt;
 CAEE:155-LAB-:101 F 12-3P  502 DAVIS CCN=14047&lt;br /&gt;
 PE:4-LAB MW 3-4P  HEARST POOL CCN=68264&lt;br /&gt;
 ES,-P,-AM:102D-LEC TuTh 11-1230P  150 GSPP CCN=29265&lt;br /&gt;
 ES,-P,-AM:102D-DIS-:102 W 1-2P  321 HAVILAND CCN=29271&lt;br /&gt;
&lt;br /&gt;
==Spring 07==&lt;br /&gt;
===Pre-planning stages===&lt;br /&gt;
Here I'm undecided about which of Math 55 and CS 70 to take. I'm also waiting on a music class to find out when it meets. apart from that this schedule is set.&lt;br /&gt;
&amp;lt;TABLE class=stbl cellpadding=5&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD class=shead&amp;gt;SCHEDULE&amp;lt;/TD&amp;gt;&amp;lt;TD class=shead colspan=1&amp;gt;Mon&amp;lt;/TD&amp;gt;&amp;lt;TD class=shead colspan=1&amp;gt;Tue&amp;lt;/TD&amp;gt;&amp;lt;TD class=shead colspan=1&amp;gt;Wed&amp;lt;/TD&amp;gt;&amp;lt;TD class=shead colspan=1&amp;gt;Thu&amp;lt;/TD&amp;gt;&amp;lt;TD class=shead colspan=2&amp;gt;Fri&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1000&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#cfcfc4'&amp;gt;MUS:51 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  135 MORRISON   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty rowspan=4&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#cfcfc4'&amp;gt;MUS:51 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  135 MORRISON   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty rowspan=4&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#cfcfc4'&amp;gt;MUS:51 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  135 MORRISON   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty1 rowspan=8&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1000&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1030&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1030&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1100&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#fec2c7'&amp;gt;SLAL:105B LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  258 DWINELLE   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#fec2c7'&amp;gt;SLAL:105B LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  258 DWINELLE   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#fec2c7'&amp;gt;SLAL:105B LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  258 DWINELLE   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1100&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1130&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1130&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1200&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#fbd1d0'&amp;gt;IS:4 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  2030 VALLEY LSB   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#fbd1d0'&amp;gt;IS:4 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  2030 VALLEY LSB   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#fbd1d0'&amp;gt;IS:4 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  2030 VALLEY LSB   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#fbd1d0'&amp;gt;IS:4 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  2030 VALLEY LSB   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#fbd1d0'&amp;gt;IS:4 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  2030 VALLEY LSB   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1200&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1230&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1230&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1300&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#f0fbef'&amp;gt;CS:61C LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  2050 VALLEY LSB   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty rowspan=5&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#f0fbef'&amp;gt;CS:61C LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  2050 VALLEY LSB   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty rowspan=5&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#f0fbef'&amp;gt;CS:61C LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  2050 VALLEY LSB   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1300&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1330&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1330&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1400&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#dde9d7'&amp;gt;MATH:55 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  277 CORY   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#dde9d7'&amp;gt;MATH:55 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  277 CORY   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#f5d4cd'&amp;gt;CS:70 DIS :103&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  85 EVANS   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#dde9d7'&amp;gt;MATH:55 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  277 CORY   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1400&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1430&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1430&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1500&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty1 rowspan=4&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty1 rowspan=4&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty1 rowspan=4&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty1 rowspan=4&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1500&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1530&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=3 style='background:#f5d4cd'&amp;gt;CS:70 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  2 LECONTE   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=3 style='background:#f5d4cd'&amp;gt;CS:70 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  2 LECONTE   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1530&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1600&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1600&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1630&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1630&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;/TABLE&amp;gt;&lt;br /&gt;
==Fall 06==&lt;br /&gt;
===As of Sep 8===&lt;br /&gt;
&amp;lt;TABLE class=stbl cellpadding=5 style=&amp;quot;text-align:center;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD class=shead&amp;gt;SCHEDULE&amp;lt;/TD&amp;gt;&amp;lt;TD class=shead colspan=1&amp;gt;Mon&amp;lt;/TD&amp;gt;&amp;lt;TD class=shead colspan=1&amp;gt;Tue&amp;lt;/TD&amp;gt;&amp;lt;TD class=shead colspan=1&amp;gt;Wed&amp;lt;/TD&amp;gt;&amp;lt;TD class=shead colspan=1&amp;gt;Thu&amp;lt;/TD&amp;gt;&amp;lt;TD class=shead colspan=1&amp;gt;Fri&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;800&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty1 rowspan=4&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=3 style='background:#cfcfc4'&amp;gt;MATH:54 DIS :101&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  61 EVANS   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty1 rowspan=4&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=3 style='background:#cfcfc4'&amp;gt;MATH:54 DIS :101&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  61 EVANS   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty1 rowspan=4&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;800&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;830&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;830&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;900&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;900&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;930&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=3 style='background:#fec2c7'&amp;gt;FRENCH:102 LEC:002&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  B4 DWINELLE   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=3 style='background:#fec2c7'&amp;gt;FRENCH:102 LEC:002&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  B4 DWINELLE   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;930&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1000&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#fbd1d0'&amp;gt;MUS:50 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  124 MORRISON   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#fbd1d0'&amp;gt;MUS:50 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  124 MORRISON   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#fbd1d0'&amp;gt;MUS:50 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  124 MORRISON   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1000&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1030&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1030&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1100&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#f0fbef'&amp;gt;SLAL:105A LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  205 DWINELLE   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty rowspan=2&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#f0fbef'&amp;gt;SLAL:105A LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  205 DWINELLE   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#dde9d7'&amp;gt;SLAL:114 SLF&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  205 DWINELLE   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#f0fbef'&amp;gt;SLAL:105A LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  205 DWINELLE   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1100&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1130&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1130&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1200&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#f5d4cd'&amp;gt;IS:3 LEC:003&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  283 DWINELLE   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#f5d4cd'&amp;gt;IS:3 LEC:003&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  283 DWINELLE   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#f5d4cd'&amp;gt;IS:3 LEC:003&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  283 DWINELLE   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#f5d4cd'&amp;gt;IS:3 LEC:003&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  283 DWINELLE   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#f5d4cd'&amp;gt;IS:3 LEC:003&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  283 DWINELLE   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1200&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1230&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1230&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1300&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#d2e3c7'&amp;gt;MUS:61 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  117 MORRISON   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=4 style='background:#c9e5cb'&amp;gt;CS:61B LAB :013&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  277 SODA   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#d2e3c7'&amp;gt;MUS:61 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  117 MORRISON   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty rowspan=2&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#d2e3c7'&amp;gt;MUS:61 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  117 MORRISON   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1300&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1330&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1330&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1400&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty1 rowspan=2&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty1 rowspan=2&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#c9e5cb'&amp;gt;CS:61B DIS :113&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  101 BARROWS   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty1 rowspan=2&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1400&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1430&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1430&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1500&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#cfcfc4'&amp;gt;MATH:54 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  155 DWINELLE   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#edd5f8'&amp;gt;PE:4 LAB:003&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  HEARST POOL   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#cfcfc4'&amp;gt;MATH:54 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  155 DWINELLE   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#edd5f8'&amp;gt;PE:4 LAB:003&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  HEARST POOL   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#cfcfc4'&amp;gt;MATH:54 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  155 DWINELLE   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1500&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1530&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1530&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1600&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#c9e5cb'&amp;gt;CS:61B LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  145 DWINELLE   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty rowspan=2&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#c9e5cb'&amp;gt;CS:61B LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  145 DWINELLE   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty rowspan=2&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#c9e5cb'&amp;gt;CS:61B LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  145 DWINELLE   &amp;lt;br&amp;gt;&amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1600&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1630&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1630&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;/TABLE&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Before the start of classes (Aug 28)===&lt;br /&gt;
&amp;lt;TABLE class=stbl cellpadding=5 cellspacing=0 border=0 style=&amp;quot;text-align: center;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD class=shead&amp;gt;SCHEDULE&amp;lt;/TD&amp;gt;&amp;lt;TD class=shead colspan=1&amp;gt;Mon&amp;lt;/TD&amp;gt;&amp;lt;TD class=shead colspan=1&amp;gt;Tue&amp;lt;/TD&amp;gt;&amp;lt;TD class=shead colspan=1&amp;gt;Wed&amp;lt;/TD&amp;gt;&amp;lt;TD class=shead colspan=1&amp;gt;Thu&amp;lt;/TD&amp;gt;&amp;lt;TD class=shead colspan=1&amp;gt;Fri&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;800&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty1 rowspan=4&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=3 style='background:#cfcfc4'&amp;gt;MATH:54 DIS :101&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  61 EVANS   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty1 rowspan=4&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=3 style='background:#cfcfc4'&amp;gt;MATH:54 DIS :101&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  61 EVANS   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty1 rowspan=4&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;800&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;830&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;830&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;900&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;900&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;930&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=3 style='background:#fec2c7'&amp;gt;FRENCH:102 LEC:002&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  B4 DWINELLE   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=3 style='background:#fec2c7'&amp;gt;FRENCH:102 LEC:002&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  B4 DWINELLE   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;930&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1000&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#fbd1d0'&amp;gt;MUS:50 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  124 MORRISON   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#fbd1d0'&amp;gt;MUS:50 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  124 MORRISON   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#fbd1d0'&amp;gt;MUS:50 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  124 MORRISON   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1000&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1030&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1030&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1100&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#f0fbef'&amp;gt;MUS:61 LEC:002&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  128 MORRISON   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty rowspan=2&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#f0fbef'&amp;gt;MUS:61 LEC:002&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  128 MORRISON   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty rowspan=2&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#f0fbef'&amp;gt;MUS:61 LEC:002&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  128 MORRISON   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1100&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1130&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1130&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1200&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#dde9d7'&amp;gt;IS:3 LEC:003&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  C320 CHEIT   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#dde9d7'&amp;gt;IS:3 LEC:003&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  C320 CHEIT   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#dde9d7'&amp;gt;IS:3 LEC:003&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  C320 CHEIT   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#dde9d7'&amp;gt;IS:3 LEC:003&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  C320 CHEIT   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#dde9d7'&amp;gt;IS:3 LEC:003&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  C320 CHEIT   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1200&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1230&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1230&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1300&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=4 style='background:#f5d4cd'&amp;gt;PE:1 LAB:007&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  234 HEARST GYM   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=4 style='background:#d2e3c7'&amp;gt;CS:61B LAB :013&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  277 SODA   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty1 rowspan=4&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty rowspan=2&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty1 rowspan=4&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1300&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1330&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1330&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1400&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#d2e3c7'&amp;gt;CS:61B DIS :113&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  78 BARROWS   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1400&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1430&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1430&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1500&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#cfcfc4'&amp;gt;MATH:54 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  155 DWINELLE   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#c9e5cb'&amp;gt;PE:4 LAB:003&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  HEARST POOL   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#cfcfc4'&amp;gt;MATH:54 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  155 DWINELLE   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#c9e5cb'&amp;gt;PE:4 LAB:003&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  HEARST POOL   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#cfcfc4'&amp;gt;MATH:54 LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  155 DWINELLE   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1500&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1530&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1530&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1600&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#d2e3c7'&amp;gt;CS:61B LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  145 DWINELLE   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty rowspan=2&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#d2e3c7'&amp;gt;CS:61B LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  145 DWINELLE   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sempty rowspan=2&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD class=sdata rowspan=2 style='background:#d2e3c7'&amp;gt;CS:61B LEC&amp;lt;BR&amp;gt;&amp;lt;SMALL&amp;gt;  145 DWINELLE   &amp;lt;/SMALL&amp;gt;&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1600&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1630&amp;lt;/TD&amp;gt;&amp;lt;TD nowrap class=shead&amp;gt;1630&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;/TABLE&amp;gt;&lt;br /&gt;
There’s also another class that doesn’t have a scheduled meeting time, Slavic 114.&lt;br /&gt;
&lt;br /&gt;
==Spring 06==&lt;br /&gt;
&lt;br /&gt;
==Fall 05==&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Main_Page&amp;diff=24439</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Main_Page&amp;diff=24439"/>
		<updated>2023-02-20T03:57:02Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Changed redirect target from lensowiki:Community portal to lensowiki:Community Portal&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#redirect[[lensowiki:Community Portal]]&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Main_Page&amp;diff=24438</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Main_Page&amp;diff=24438"/>
		<updated>2023-02-20T03:56:47Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Redirected page to lensowiki:Community portal&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#redirect[[lensowiki:Community portal]]&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=lensowiki:Community_Portal&amp;diff=24437</id>
		<title>lensowiki:Community Portal</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=lensowiki:Community_Portal&amp;diff=24437"/>
		<updated>2023-02-20T03:55:49Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: good times&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Welcome to the '''Community Portal'''! For more information about the lensowiki project, see the [[lensowiki:About|About]] page.&lt;br /&gt;
&lt;br /&gt;
New articles will be announced and listed here, listed by subject.&lt;br /&gt;
&lt;br /&gt;
==Computer Science/IT==&lt;br /&gt;
*[[CS]] ''list of various CS projects, including personal projects and classwork''&lt;br /&gt;
*[[DC|DC++]] ''config instructions for Cal hub''&lt;br /&gt;
*[[lensowiki:Installation caveats|Installation caveats]] ''details the problems inherent in a MediaWiki installation with a UTF-8 encoding for the database tables and functional workarounds''&lt;br /&gt;
*[[Sony Clie on Mac OS X]] ''provides instructions for syncing Sony Clie handhelds on Mac OS X without Missing Sync''&lt;br /&gt;
&lt;br /&gt;
==History==&lt;br /&gt;
*[[History of Alsace and Lorraine]] ''in French''&lt;br /&gt;
&lt;br /&gt;
==Home Improvement==&lt;br /&gt;
*[[Home improvement]]&lt;br /&gt;
&lt;br /&gt;
==Personal records==&lt;br /&gt;
*[[Caltrain]] ''a nasty incident on Caltrain in which I was forced off a train after paying my fare with Translink''&lt;br /&gt;
*[[Photo shoots]] ''photo-shooting locations and notes''&lt;br /&gt;
*[[Swimming]] ''includes swimming workouts''&lt;br /&gt;
*[[Class schedule]] ''class schedules for past and current semesters''&lt;br /&gt;
*[[Academic plans]] ''4-year plans for graduation''&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61b/Projects/Ocean/SimText.java&amp;diff=24427</id>
		<title>Computer Science/61b/Projects/Ocean/SimText.java</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61b/Projects/Ocean/SimText.java&amp;diff=24427"/>
		<updated>2023-02-20T03:51:37Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61b/Projects/Ocean/SimText.java to Computer Science/61b/Projects/Ocean/SimText.java&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;:''The author of this file is Jonathan Shewchuk; consequently, I cannot make it freely available.''&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61b/Projects/Ocean/SimText.java&amp;diff=24428</id>
		<title>CS/61b/Projects/Ocean/SimText.java</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61b/Projects/Ocean/SimText.java&amp;diff=24428"/>
		<updated>2023-02-20T03:51:37Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61b/Projects/Ocean/SimText.java to Computer Science/61b/Projects/Ocean/SimText.java&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[Computer Science/61b/Projects/Ocean/SimText.java]]&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61b/Projects/Ocean/Simulation.java&amp;diff=24429</id>
		<title>Computer Science/61b/Projects/Ocean/Simulation.java</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61b/Projects/Ocean/Simulation.java&amp;diff=24429"/>
		<updated>2023-02-20T03:51:37Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61b/Projects/Ocean/Simulation.java to Computer Science/61b/Projects/Ocean/Simulation.java&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;:''The author of this file is Jonathan Shewchuk; consequently, I cannot make it freely available.''&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61b/Projects/Ocean/Simulation.java&amp;diff=24430</id>
		<title>CS/61b/Projects/Ocean/Simulation.java</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61b/Projects/Ocean/Simulation.java&amp;diff=24430"/>
		<updated>2023-02-20T03:51:37Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61b/Projects/Ocean/Simulation.java to Computer Science/61b/Projects/Ocean/Simulation.java&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[Computer Science/61b/Projects/Ocean/Simulation.java]]&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61b/Projects/Ocean/Test4.java&amp;diff=24431</id>
		<title>Computer Science/61b/Projects/Ocean/Test4.java</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61b/Projects/Ocean/Test4.java&amp;diff=24431"/>
		<updated>2023-02-20T03:51:37Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61b/Projects/Ocean/Test4.java to Computer Science/61b/Projects/Ocean/Test4.java&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{code}}&lt;br /&gt;
 /* Test4.java */&lt;br /&gt;
 &lt;br /&gt;
 public class Test4 {&lt;br /&gt;
   public static int empty;&lt;br /&gt;
   public static int shark;&lt;br /&gt;
   public static int fish;&lt;br /&gt;
 &lt;br /&gt;
   public static void init() {&lt;br /&gt;
     empty = Ocean.EMPTY;&lt;br /&gt;
     shark = Ocean.SHARK;&lt;br /&gt;
     fish = Ocean.FISH;&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61b/Projects/Ocean/Test4.java&amp;diff=24432</id>
		<title>CS/61b/Projects/Ocean/Test4.java</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61b/Projects/Ocean/Test4.java&amp;diff=24432"/>
		<updated>2023-02-20T03:51:37Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61b/Projects/Ocean/Test4.java to Computer Science/61b/Projects/Ocean/Test4.java&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[Computer Science/61b/Projects/Ocean/Test4.java]]&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61b/Projects/Ocean/TypeAndSize.java&amp;diff=24433</id>
		<title>Computer Science/61b/Projects/Ocean/TypeAndSize.java</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61b/Projects/Ocean/TypeAndSize.java&amp;diff=24433"/>
		<updated>2023-02-20T03:51:37Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61b/Projects/Ocean/TypeAndSize.java to Computer Science/61b/Projects/Ocean/TypeAndSize.java&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;:''The author of this file is Jonathan Shewchuk; consequently, I cannot make it freely available.''&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61b/Projects/Ocean/TypeAndSize.java&amp;diff=24434</id>
		<title>CS/61b/Projects/Ocean/TypeAndSize.java</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61b/Projects/Ocean/TypeAndSize.java&amp;diff=24434"/>
		<updated>2023-02-20T03:51:37Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61b/Projects/Ocean/TypeAndSize.java to Computer Science/61b/Projects/Ocean/TypeAndSize.java&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[Computer Science/61b/Projects/Ocean/TypeAndSize.java]]&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61c&amp;diff=24435</id>
		<title>Computer Science/61c</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61c&amp;diff=24435"/>
		<updated>2023-02-20T03:51:37Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61c to Computer Science/61c&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;*[[/Projects]]&lt;br /&gt;
*[[/Homework]]&lt;br /&gt;
&lt;br /&gt;
==External links==&lt;br /&gt;
*[http://inst.eecs.berkeley.edu/~cs61c/sp07/ Class website]&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61c&amp;diff=24436</id>
		<title>CS/61c</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61c&amp;diff=24436"/>
		<updated>2023-02-20T03:51:37Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61c to Computer Science/61c&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[Computer Science/61c]]&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61b/Projects/Network/player/Gameboard.java&amp;diff=24410</id>
		<title>CS/61b/Projects/Network/player/Gameboard.java</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61b/Projects/Network/player/Gameboard.java&amp;diff=24410"/>
		<updated>2023-02-20T03:51:36Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61b/Projects/Network/player/Gameboard.java to Computer Science/61b/Projects/Network/player/Gameboard.java&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[Computer Science/61b/Projects/Network/player/Gameboard.java]]&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61b/Projects/Network/player/MachinePlayer.java&amp;diff=24411</id>
		<title>Computer Science/61b/Projects/Network/player/MachinePlayer.java</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61b/Projects/Network/player/MachinePlayer.java&amp;diff=24411"/>
		<updated>2023-02-20T03:51:36Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61b/Projects/Network/player/MachinePlayer.java to Computer Science/61b/Projects/Network/player/MachinePlayer.java&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{code}}&lt;br /&gt;
 /* MachinePlayer.java */&lt;br /&gt;
 &lt;br /&gt;
 package player;&lt;br /&gt;
 &lt;br /&gt;
 /**&lt;br /&gt;
  *  An implementation of an automatic Network player.  Keeps track of moves&lt;br /&gt;
  *  made by both players.  Can select a move for itself.&lt;br /&gt;
  */&lt;br /&gt;
 public class MachinePlayer extends Player {&lt;br /&gt;
 	&lt;br /&gt;
 	private int color;&lt;br /&gt;
 	private int opponent;&lt;br /&gt;
 	private int depth;&lt;br /&gt;
 	private Gameboard board;&lt;br /&gt;
 	&lt;br /&gt;
 	public static final int SDEPTH = 2;&lt;br /&gt;
 	&lt;br /&gt;
 	// Creates a machine player with the given color.  Color is either 0 (black)&lt;br /&gt;
 	// or 1 (white).  (White has the first move.)&lt;br /&gt;
 	public MachinePlayer(int color) {&lt;br /&gt;
 		this(color, SDEPTH);&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	// Creates a machine player with the given color and search depth.  Color is&lt;br /&gt;
 	// either 0 (black) or 1 (white).  (White has the first move.)&lt;br /&gt;
 	public MachinePlayer(int color, int searchDepth) {&lt;br /&gt;
 		this.color = color;&lt;br /&gt;
 		opponent = Gameboard.generateOpponent(color);&lt;br /&gt;
 		depth = searchDepth;&lt;br /&gt;
 		board = new Gameboard();&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	// Returns a new move by &amp;quot;this&amp;quot; player.  Internally records the move (updates&lt;br /&gt;
 	// the internal game board) as a move by &amp;quot;this&amp;quot; player.&lt;br /&gt;
 	public Move chooseMove() {&lt;br /&gt;
 		Move winningmove = board.evalTree(color, depth);&lt;br /&gt;
 		board.performMove(color, winningmove);&lt;br /&gt;
 		return winningmove;&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	// If the Move m is legal, records the move as a move by the opponent&lt;br /&gt;
 	// (updates the internal game board) and returns true.  If the move is&lt;br /&gt;
 	// illegal, returns false without modifying the internal state of &amp;quot;this&amp;quot;&lt;br /&gt;
 	// player.  This method allows your opponents to inform you of their moves.&lt;br /&gt;
 	public boolean opponentMove(Move m) {&lt;br /&gt;
 		return board.performMove(opponent, m);&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	// If the Move m is legal, records the move as a move by &amp;quot;this&amp;quot; player&lt;br /&gt;
 	// (updates the internal game board) and returns true.  If the move is&lt;br /&gt;
 	// illegal, returns false without modifying the internal state of &amp;quot;this&amp;quot;&lt;br /&gt;
 	// player.  This method is used to help set up &amp;quot;Network problems&amp;quot; for your&lt;br /&gt;
 	// player to solve.&lt;br /&gt;
 	public boolean forceMove(Move m) {&lt;br /&gt;
 		return board.performMove(color, m);&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	public int boardScore() {&lt;br /&gt;
 		return board.winner();&lt;br /&gt;
 	}&lt;br /&gt;
 }&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61b/Projects/Network/player/MachinePlayer.java&amp;diff=24412</id>
		<title>CS/61b/Projects/Network/player/MachinePlayer.java</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61b/Projects/Network/player/MachinePlayer.java&amp;diff=24412"/>
		<updated>2023-02-20T03:51:36Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61b/Projects/Network/player/MachinePlayer.java to Computer Science/61b/Projects/Network/player/MachinePlayer.java&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[Computer Science/61b/Projects/Network/player/MachinePlayer.java]]&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61b/Projects/Network/player/Move.java&amp;diff=24413</id>
		<title>Computer Science/61b/Projects/Network/player/Move.java</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61b/Projects/Network/player/Move.java&amp;diff=24413"/>
		<updated>2023-02-20T03:51:36Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61b/Projects/Network/player/Move.java to Computer Science/61b/Projects/Network/player/Move.java&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt; /* Move.java  */&lt;br /&gt;
 &lt;br /&gt;
 package player;&lt;br /&gt;
 &lt;br /&gt;
 /**&lt;br /&gt;
  *  A public class for holding all the fields in a move.  This class is a&lt;br /&gt;
  *  container for data, not an ADT; hence, all fields are public.&lt;br /&gt;
  *&lt;br /&gt;
  *  The moveKind field stores the type of move.  The x-coordinates index the&lt;br /&gt;
  *  horizontal direction (left to right) and the y-coordinates index the&lt;br /&gt;
  *  vertical direction (top to bottom).  x- and y-coordinates start at zero.&lt;br /&gt;
  *&lt;br /&gt;
  *  DO NOT CHANGE THIS FILE.&lt;br /&gt;
  */&lt;br /&gt;
 public class Move {&lt;br /&gt;
&lt;br /&gt;
{{notmine|Jonathan Shewchuk}}&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61b/Projects/Network/player/Move.java&amp;diff=24414</id>
		<title>CS/61b/Projects/Network/player/Move.java</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61b/Projects/Network/player/Move.java&amp;diff=24414"/>
		<updated>2023-02-20T03:51:36Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61b/Projects/Network/player/Move.java to Computer Science/61b/Projects/Network/player/Move.java&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[Computer Science/61b/Projects/Network/player/Move.java]]&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61b/Projects/Network/player/Player.java&amp;diff=24415</id>
		<title>Computer Science/61b/Projects/Network/player/Player.java</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61b/Projects/Network/player/Player.java&amp;diff=24415"/>
		<updated>2023-02-20T03:51:36Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61b/Projects/Network/player/Player.java to Computer Science/61b/Projects/Network/player/Player.java&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{code}}&lt;br /&gt;
 /* Player.java */&lt;br /&gt;
 &lt;br /&gt;
 package player;&lt;br /&gt;
 &lt;br /&gt;
 /**&lt;br /&gt;
  *  A class that is extended by all Network players (human and machine).&lt;br /&gt;
  *&lt;br /&gt;
  *  DO NOT CHANGE THIS FILE.&lt;br /&gt;
  */&lt;br /&gt;
 public abstract class Player {&lt;br /&gt;
   // This player's name as recognized by the game Network.&lt;br /&gt;
   public String myName;&lt;br /&gt;
 &lt;br /&gt;
   // Returns a new move by &amp;quot;this&amp;quot; player.  Internally records the move (updates&lt;br /&gt;
   // the internal game board) as a move by &amp;quot;this&amp;quot; player.&lt;br /&gt;
   public abstract Move chooseMove();&lt;br /&gt;
 &lt;br /&gt;
   // If the Move m is legal, records the move as a move by the opponent&lt;br /&gt;
   // (updates the internal game board) and returns true.  If the move is&lt;br /&gt;
   // illegal, returns false without modifying the internal state of &amp;quot;this&amp;quot;&lt;br /&gt;
   // player.  This method allows your opponents to inform you of their moves.&lt;br /&gt;
   public abstract boolean opponentMove(Move m);&lt;br /&gt;
 &lt;br /&gt;
   // If the Move m is legal, records the move as a move by &amp;quot;this&amp;quot; player&lt;br /&gt;
   // (updates the internal game board) and returns true.  If the move is&lt;br /&gt;
   // illegal, returns false without modifying the internal state of &amp;quot;this&amp;quot;&lt;br /&gt;
   // player.  This method is used to help set up &amp;quot;Network problems&amp;quot; for your&lt;br /&gt;
   // player to solve.&lt;br /&gt;
   public abstract boolean forceMove(Move m);&lt;br /&gt;
 &lt;br /&gt;
 }&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61b/Projects/Network/player/Player.java&amp;diff=24416</id>
		<title>CS/61b/Projects/Network/player/Player.java</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61b/Projects/Network/player/Player.java&amp;diff=24416"/>
		<updated>2023-02-20T03:51:36Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61b/Projects/Network/player/Player.java to Computer Science/61b/Projects/Network/player/Player.java&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[Computer Science/61b/Projects/Network/player/Player.java]]&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61b/Projects/Ocean&amp;diff=24417</id>
		<title>Computer Science/61b/Projects/Ocean</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61b/Projects/Ocean&amp;diff=24417"/>
		<updated>2023-02-20T03:51:36Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61b/Projects/Ocean to Computer Science/61b/Projects/Ocean&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Files==&lt;br /&gt;
===Main Ocean files===&lt;br /&gt;
*[[/Ocean.java]]&lt;br /&gt;
*[[/RunLengthEncoding.java]]&lt;br /&gt;
===Helper linked-list ADT===&lt;br /&gt;
*[[/DList.java]]&lt;br /&gt;
*[[/DListNode.java]]&lt;br /&gt;
===Testing files===&lt;br /&gt;
*[[/SimText.java]]&lt;br /&gt;
*[[/Simulation.java]]&lt;br /&gt;
*[[/Test4.java]]&lt;br /&gt;
*[[/TypeAndSize.java]]&lt;br /&gt;
&lt;br /&gt;
==Grade==&lt;br /&gt;
20/20&lt;br /&gt;
&lt;br /&gt;
==Description==&lt;br /&gt;
                               CS 61B  Project 1&lt;br /&gt;
                                Sharks and Fish&lt;br /&gt;
                      Due 4pm Friday, September 29, 2006&lt;br /&gt;
&lt;br /&gt;
Warning:  This project is time-consuming.  Start early.&lt;br /&gt;
&lt;br /&gt;
This is an individual assignment; you may not share code with other students.&lt;br /&gt;
&lt;br /&gt;
Getting started: You will find the code for this assignment in $master/hw/pj1/.&lt;br /&gt;
Start by copying it into your own pj1 directory.&lt;br /&gt;
&lt;br /&gt;
In this project you will implement a simulation of an ocean containing sharks&lt;br /&gt;
and fish.  You will also write code to convert an ocean into a run-length&lt;br /&gt;
encoding and back.  The ocean is rectangular, but the edges are connected&lt;br /&gt;
together in a topological donut or torus.  This means that the top (North) and&lt;br /&gt;
bottom (South) edges are considered adjacent, so if you start at the top edge&lt;br /&gt;
and go up, you'll be at the bottom edge (just like in the video game&lt;br /&gt;
Asteroids).  Similarly, the East and West edges are connected (just like in&lt;br /&gt;
Pac Man).  The ocean is divided into square cells, which are indexed as follows&lt;br /&gt;
(for a 4x3 ocean):&lt;br /&gt;
&lt;br /&gt;
                         ------&amp;gt; x&lt;br /&gt;
 &lt;br /&gt;
                     |   -----------------------------&lt;br /&gt;
                     |   | 0, 0 | 1, 0 | 2, 0 | 3, 0 |&lt;br /&gt;
                   y |   -----------------------------&lt;br /&gt;
                     |   | 0, 1 | 1, 1 | 2, 1 | 3, 1 |&lt;br /&gt;
                     v   -----------------------------&lt;br /&gt;
                         | 0, 2 | 1, 2 | 2, 2 | 3, 2 |&lt;br /&gt;
                         -----------------------------&lt;br /&gt;
&lt;br /&gt;
Note that the origin is in the upper left; the x-coordinate increases as you&lt;br /&gt;
move right, and the y-coordinate increases as you go down.  (This conforms to&lt;br /&gt;
Java's graphics commands, though you won't need to use them directly in this&lt;br /&gt;
project.)  You can also refer to locations such as (4, 0) or (-4, 3), which are&lt;br /&gt;
both the same as (0, 0) in a 4x3 ocean.  (More generally, the coordinates in&lt;br /&gt;
an ixj ocean are taken modulo i for the x-coordinate, which is horizontal, and&lt;br /&gt;
modulo j for the y-coordinate, which is vertical.)  Any pair of integers will&lt;br /&gt;
give you a valid position in the grid by &amp;quot;wrapping around&amp;quot; at the edges.&lt;br /&gt;
&lt;br /&gt;
(Hint:  programming will be a lot easier if you write helper functions that do&lt;br /&gt;
the wrapping around for you, and use them in all your methods, so you don't&lt;br /&gt;
have to think about it again.)&lt;br /&gt;
&lt;br /&gt;
There are two kinds of entities in this ocean:  sharks and fish.  The sharks&lt;br /&gt;
and fish breed, eat, and die in the ocean.  Each cell of the grid can be&lt;br /&gt;
occupied by a single shark or fish, or it can be empty.&lt;br /&gt;
&lt;br /&gt;
===Part I:  Simulating Sharks and Fish===&lt;br /&gt;
&lt;br /&gt;
This part is worth 40% of your total score.  (8 points out of 20).&lt;br /&gt;
&lt;br /&gt;
An ocean is described by its size and the initial placement of sharks and fish&lt;br /&gt;
in the ocean.  It is also described by a parameter called the &amp;quot;starveTime&amp;quot; for&lt;br /&gt;
a shark.  This is the number of simulation timesteps that a shark can live&lt;br /&gt;
through without eating.&lt;br /&gt;
&lt;br /&gt;
The simulation proceeds in timesteps.  A &amp;quot;timestep&amp;quot; is a ''transition'' from one&lt;br /&gt;
ocean to the next.  (Don't confuse timesteps with oceans; every timestep starts&lt;br /&gt;
with one ocean and ends with another.)  The rules for how the ocean looks at&lt;br /&gt;
the end of a timestep depend only on the occupants of the cells at the&lt;br /&gt;
beginning of the timestep.  Therefore, to obtain correct behavior, you will&lt;br /&gt;
often be working with two copies of the ocean simultaneously; one representing&lt;br /&gt;
the ocean at the beginning of the timestep, and the other representing the&lt;br /&gt;
ocean at the end of the timestep.  (If you are foolish enough to try to&lt;br /&gt;
implement a timestep using just a single Ocean object, you will modify the&lt;br /&gt;
values of cells whose old values are still needed to compute the new values for&lt;br /&gt;
other cells, and thus you will compute the wrong answer.)&lt;br /&gt;
&lt;br /&gt;
The contents of any particular cell at the end of a timestep depend only on the&lt;br /&gt;
contents of that cell and its eight neighbors at the beginning of the timestep.&lt;br /&gt;
The &amp;quot;neighbors&amp;quot; are the eight adjacent cells:  the cells immediately to the&lt;br /&gt;
north, south, east, and west, as well as the four diagonal neighbors.  Here are&lt;br /&gt;
the rules:&lt;br /&gt;
&lt;br /&gt;
# If a cell contains a shark, and any of its neighbors is a fish, then the shark eats during the timestep, and it remains in the cell at the end of the timestep.  (We may have multiple sharks sharing the same fish.  This is fine; they all get enough to eat.)&lt;br /&gt;
# If a cell contains a shark, and none of its neighbors is a fish, it gets hungrier during the timestep.  If this timestep is the (starveTime + 1)th timestep the shark has gone through without eating, then the shark dies (disappears).  Otherwise, it remains in the cell.  An example demonstrating this rule appears below.&lt;br /&gt;
# If a cell contains a fish, and all of its neighbors are either empty or are other fish, then the fish stays where it is.&lt;br /&gt;
# If a cell contains a fish, and one of its neighbors is a shark, then the fish is eaten by a shark, and therefore disappears.&lt;br /&gt;
# If a cell contains a fish, and two or more of its neighbors are sharks, then a new shark is born in that cell.  Sharks are well-fed at birth; ''after'' they are born, they can survive an additional starveTime timesteps without eating. (But they will die at the end of starveTime + 1 consecutive timesteps without eating.)&lt;br /&gt;
# If a cell is empty, and fewer than two of its neighbors are fish, then the cell remains empty.&lt;br /&gt;
# If a cell is empty, at least two of its neighbors are fish, and at most one of its neighbors is a shark, then a new fish is born in that cell.&lt;br /&gt;
# If a cell is empty, at least two of its neighbors are fish, and at least two of its neighbors are sharks, then a new shark is born in that cell.  (The new shark is well-fed at birth, even though it hasn't eaten a fish yet.)&lt;br /&gt;
&lt;br /&gt;
====starveTime Examples====&lt;br /&gt;
The following example demonstrates exactly when sharks die.  Suppose the&lt;br /&gt;
starveTime is 3.  Suppose the initial ocean, Ocean 0, contains a well-fed&lt;br /&gt;
shark (A).  If that shark never gets to eat, it will survive three timesteps&lt;br /&gt;
without food, making it to Ocean 3; but it will be dead by Ocean 4.  Another&lt;br /&gt;
shark is born in Ocean 1, and is fed during the transition from Ocean 2 to&lt;br /&gt;
Ocean 3, but is never fed again.  It survives to Ocean 6, but it is dead by&lt;br /&gt;
Ocean 7.&lt;br /&gt;
&lt;br /&gt;
 Ocean 0    shark A (well-fed)          [empty cell]&lt;br /&gt;
 timestep                               shark B born&lt;br /&gt;
 Ocean 1    shark A                     shark B (well-fed)&lt;br /&gt;
 timestep&lt;br /&gt;
 Ocean 2    shark A                     shark B&lt;br /&gt;
 timestep                               shark B eats a fish (born last timestep)&lt;br /&gt;
 Ocean 3    shark A                     shark B (well-fed)&lt;br /&gt;
 timestep   shark A dies&lt;br /&gt;
 Ocean 4    [empty cell]                shark B&lt;br /&gt;
 timestep&lt;br /&gt;
 Ocean 5                                shark B&lt;br /&gt;
 timestep&lt;br /&gt;
 Ocean 6                                shark B&lt;br /&gt;
 timestep                               shark B dies&lt;br /&gt;
 Ocean 7                                [empty cell]&lt;br /&gt;
&lt;br /&gt;
====Your task====&lt;br /&gt;
Fill in the implementation of the Ocean class.  We have already provided you&lt;br /&gt;
with the public method definitions you will need.  You are required to provide&lt;br /&gt;
implementations of all the methods whose prototypes appear in Ocean.java.&lt;br /&gt;
Among these methods is a constructor that takes three integers as input,&lt;br /&gt;
representing the size of the ocean and the starveTime of the sharks, and&lt;br /&gt;
returns an ocean of the specified size.  For example, the statement&lt;br /&gt;
&lt;br /&gt;
    Ocean sea = new Ocean(i, j, starveTime);&lt;br /&gt;
&lt;br /&gt;
should create an ixj Ocean object.  In your implementation, you may define any&lt;br /&gt;
fields, additional methods, additional classes, or other .java files you wish,&lt;br /&gt;
but you cannot change the prototypes in Ocean.java.  We will test your code by&lt;br /&gt;
calling your methods directly, so it is important that you follow this rule.&lt;br /&gt;
You should read Ocean.java carefully for an explanation of what methods you&lt;br /&gt;
must write.  The most important of these is timeStep(), the method that&lt;br /&gt;
performs your simulation.&lt;br /&gt;
&lt;br /&gt;
Your Ocean class should represent the ocean as one or more simple two-&lt;br /&gt;
dimensional arrays.  It is up to you decide how to represent each element of&lt;br /&gt;
the array (in particular, whether it is empty or contains a shark or fish, and&lt;br /&gt;
if it's a shark, how long ago it last ate).  Your internal representation is&lt;br /&gt;
not required to use the constants EMPTY, SHARK, and FISH, which are part of the&lt;br /&gt;
public interface, but it can if you want.  However, the cellContents() method&lt;br /&gt;
must return these constants--you cannot change this part of the interface.&lt;br /&gt;
&lt;br /&gt;
We have provided Java classes to help you debug your implementation and animate&lt;br /&gt;
your ocean, in these files:&lt;br /&gt;
&lt;br /&gt;
    Simulation.java&lt;br /&gt;
    SimText.java&lt;br /&gt;
&lt;br /&gt;
The Simulation and SimText classes (which consist primarily of a simulation&lt;br /&gt;
driver called main) generate random input to initialize the ocean, and animate&lt;br /&gt;
the sequence of oceans returned by the timeStep method of your Ocean class.  So&lt;br /&gt;
that they can initialize your Ocean and monitor the fish and sharks in your&lt;br /&gt;
Ocean during the simulation, you must implement the methods addFish, addShark,&lt;br /&gt;
cellContents, width, and height.&lt;br /&gt;
&lt;br /&gt;
The Simulation and SimText programs take up to three command-line parameters.&lt;br /&gt;
The first two specify the width and height of the ocean.  The third parameter&lt;br /&gt;
specifies the value of starveTime.  For example, if you run&lt;br /&gt;
&lt;br /&gt;
    java Simulation 25 30 1&lt;br /&gt;
&lt;br /&gt;
then Simulation will animate a 25x30 ocean with a starveTime of 1.  If you run&lt;br /&gt;
&amp;quot;java Simulation&amp;quot; with no parameters, by default Simulation will animate a&lt;br /&gt;
80x80 ocean with a starveTime of 3.  (SimText animates a 50x25 ocean using text&lt;br /&gt;
on your terminal.)  With some choices of parameters, the ocean quickly dies&lt;br /&gt;
out; with others, it teems forever.&lt;br /&gt;
&lt;br /&gt;
In the animation produced by Simulation, sharks are red squares and fish are&lt;br /&gt;
green squares.  In the animation produced by SimText, sharks are 'S' characters&lt;br /&gt;
and fish are '~' characters.  Simulation is more fun to watch, but SimText may&lt;br /&gt;
be easier to use for debugging and remote access.&lt;br /&gt;
&lt;br /&gt;
===Part II:  Converting a Run-Length Encoding to an Ocean===&lt;br /&gt;
&lt;br /&gt;
This part is worth 25% of your total score.  (5 points out of 20).&lt;br /&gt;
&lt;br /&gt;
For a large ocean, an Ocean object can consume quite a bit of memory or disk&lt;br /&gt;
space.  For long-term storage, we can store an Ocean more efficiently if we&lt;br /&gt;
represent it as a &amp;quot;run-length encoding.&amp;quot;  Imagine taking all the rows of cells&lt;br /&gt;
in the ocean, and connecting them into one long strip.  Think of the cells as&lt;br /&gt;
being numbered thusly:&lt;br /&gt;
&lt;br /&gt;
                        -----------------------------&lt;br /&gt;
                        |   0  |   1  |   2  |   3  |&lt;br /&gt;
                        -----------------------------&lt;br /&gt;
                        |   4  |   5  |   6  |   7  |&lt;br /&gt;
                        -----------------------------&lt;br /&gt;
                        |   8  |   9  |  10  |  11  |&lt;br /&gt;
                        -----------------------------&lt;br /&gt;
&lt;br /&gt;
Typically, many regions of this strip are &amp;quot;runs&amp;quot; of many empty cells in a row,&lt;br /&gt;
or many fish in a row, or many equally-hungry sharks in a row.  Run-length&lt;br /&gt;
encoding is a technique in which a sequence of identical consecutive cells are&lt;br /&gt;
represented as a single record or object.  For instance, the following strip of&lt;br /&gt;
fish (F), sharks fed two timesteps ago (S2), and empty cells (.):&lt;br /&gt;
&lt;br /&gt;
            ------------------------------------------------------&lt;br /&gt;
            | F | F | F | S2 | S2 | S2 | S2 | S2 | . | . | . | . |&lt;br /&gt;
            ------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
could be represented with just three records, each representing one &amp;quot;run&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
                              ------------------&lt;br /&gt;
                              | F3 | S2,5 | .4 |&lt;br /&gt;
                              ------------------&lt;br /&gt;
&lt;br /&gt;
&amp;quot;F3&amp;quot; means that there are three consecutive fish, followed by &amp;quot;S2,5&amp;quot;, meaning&lt;br /&gt;
five consecutive sharks fed two timesteps ago, and then &amp;quot;.4&amp;quot;:  four empty&lt;br /&gt;
cells.  With this encoding, a huge ocean with just a few fish or sharks can be&lt;br /&gt;
stored in a tiny amount of memory.  (Note, however, that a shark that just ate&lt;br /&gt;
cannot be represented together with a shark that hasn't eaten in the last&lt;br /&gt;
timestep.  For a correct encoding, you must separate sharks based on their&lt;br /&gt;
hunger!)  If you are familiar with .GIF image files (often encountered on the&lt;br /&gt;
Web), you might be interested to know that they use run-length encoding to&lt;br /&gt;
reduce their sizes.&lt;br /&gt;
&lt;br /&gt;
Your task is to implement a RunLengthEncoding class, which represents a&lt;br /&gt;
run-length encoding as a linked list of &amp;quot;run&amp;quot; objects.  It is up to you whether&lt;br /&gt;
to use a singly- or doubly-linked list, but a doubly-linked list may make Part&lt;br /&gt;
IV easier.&lt;br /&gt;
&lt;br /&gt;
Because this is a data structures course, please use your own list class(es) or&lt;br /&gt;
ones you have learned in class.  In future courses, it will sometimes make more&lt;br /&gt;
sense for you to use a linked list class written by somebody else, such as&lt;br /&gt;
java.util.LinkedList.  However, in CS 61B this is forbidden, because I want you&lt;br /&gt;
to be always aware of exactly how your data structures work.  Likewise, you may&lt;br /&gt;
not use java.util.Vector or other built-in data structures.&lt;br /&gt;
&lt;br /&gt;
====Part II(a)====&lt;br /&gt;
Implement two constructors for RunLengthEncodings.  One constructs&lt;br /&gt;
a run-length encoding of an empty ocean, and the other constructs a run-length&lt;br /&gt;
encoding based on two arrays provided as parameters to the constructor.  These&lt;br /&gt;
arrays represent the runs that your run-length coding should contain, so you&lt;br /&gt;
are simply converting arrays to a linked list.  (See the prototype in&lt;br /&gt;
RunLengthEncoding.java.)&lt;br /&gt;
&lt;br /&gt;
====Part II(b)====&lt;br /&gt;
Your run-length encodings will only be useful if other classes&lt;br /&gt;
have the ability to read them after you create them.  Therefore, implement the&lt;br /&gt;
nextRun() and restartRuns() methods.  These two methods work together to return&lt;br /&gt;
all the runs in a run-length encoding to an outside application, one by one.&lt;br /&gt;
Each time nextRun() is invoked, it returns a different run--represented as a&lt;br /&gt;
TypeAndSize object--until every run has been returned.  The first time&lt;br /&gt;
nextRun() is invoked, it returns the first run in the encoding, which contains&lt;br /&gt;
cell (0, 0).  After every run has been returned, nextRun() returns null, which&lt;br /&gt;
lets the calling program know that there are no more runs in the encoding.&lt;br /&gt;
&lt;br /&gt;
The restartRuns() method resets the enumeration, so that nextRun() will once&lt;br /&gt;
again return the first run as if it were being called for the first time.&lt;br /&gt;
Warning:  the test code will not necessarily call restartRuns() before the&lt;br /&gt;
first time nextRun() is called.&lt;br /&gt;
&lt;br /&gt;
IMPORTANT NOTE on nextRun() and restartRuns():  your methods in the&lt;br /&gt;
RunLengthEncoding class should never call these methods.  The nextRun() and&lt;br /&gt;
restartRuns() methods are provided so that ''other'' classes (specifically, the&lt;br /&gt;
Test program that autogrades your project) can read the contents of a&lt;br /&gt;
run-length encoding.  If your RunLengthEncoding methods call them, they will&lt;br /&gt;
mess up the position of the internal pointer for the other classes.&lt;br /&gt;
&lt;br /&gt;
IMPORTANT NOTE on TypeAndSize:  The Java &amp;quot;return&amp;quot; keyword only allows you to&lt;br /&gt;
return one value from a method call.  But the nextRun() method needs to return&lt;br /&gt;
two values--the length of a run, and the type of object it contains.  How can&lt;br /&gt;
it do this?  Answer:  by returning a &amp;quot;TypeAndSize&amp;quot; object.  A TypeAndSize&lt;br /&gt;
object is nothing more than a way to return two integers at once.  That's it.&lt;br /&gt;
Each time nextRun() is called, it creates a TypeAndSize object (or it will once&lt;br /&gt;
you've coded it to do so), fills in the values, and returns it to the calling&lt;br /&gt;
routine, which then throws it away.  The TypeAndSize object is part of the&lt;br /&gt;
predefined interface of your RunLengthEncoding class, so you CANNOT change it,&lt;br /&gt;
because the calling programs (including the autograder) are relying on you to&lt;br /&gt;
return TypeAndSize objects according to spec.  TypeAndSize objects are NOT&lt;br /&gt;
suitable as a way to represent a run in your run-length encoding, because they&lt;br /&gt;
do not encode a shark's hunger.&lt;br /&gt;
&lt;br /&gt;
====Part II(c)====&lt;br /&gt;
Implement a toOcean() method in the RunLengthEncoding class, which&lt;br /&gt;
converts a run-length encoding to an Ocean object.  To accomplish this, you&lt;br /&gt;
will need to implement a new addShark() method in the Ocean class, so that you&lt;br /&gt;
can specify the hunger of each shark you add to the ocean.  This way, you can&lt;br /&gt;
convert an Ocean to a run-length encoding and back again without forgetting how&lt;br /&gt;
hungry each shark was.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Read RunLengthEncoding.java carefully for an explanation of what methods you&lt;br /&gt;
must write.  The fields of the Ocean class MUST be private, and the&lt;br /&gt;
RunLengthEncoding class cannot manipulate these fields directly.  Hence, the&lt;br /&gt;
toOcean() method will rely upon the Ocean constructor and the addFish() and&lt;br /&gt;
addShark() methods.&lt;br /&gt;
&lt;br /&gt;
You cannot change any of the prototypes in RunLengthEncoding.java, and you&lt;br /&gt;
cannot change the file TypeAndSize.java.  Again, we will test your code by&lt;br /&gt;
calling your methods directly.&lt;br /&gt;
&lt;br /&gt;
===Part III:  Converting an Ocean to a Run-Length Encoding===&lt;br /&gt;
&lt;br /&gt;
This part is worth 25% of your total score.  (5 points out of 20).&lt;br /&gt;
&lt;br /&gt;
Next, write a RunLengthEncoding constructor that takes an Ocean object as its&lt;br /&gt;
sole parameter and converts it into a run-length encoding of the Ocean.  To&lt;br /&gt;
accomplish this, you will need to implement a sharkFeeding() method in the&lt;br /&gt;
Ocean class, which tells you how hungry a given shark is.  Read Ocean.java and&lt;br /&gt;
RunLengthEncoding.java carefully for an explanation of what methods you must&lt;br /&gt;
write.&lt;br /&gt;
&lt;br /&gt;
The fields of the Ocean class MUST be private, so the RunLengthEncoding&lt;br /&gt;
constructor will rely upon the width(), height(), starveTime(), cellContents(),&lt;br /&gt;
and sharkFeeding() methods.&lt;br /&gt;
&lt;br /&gt;
====Testing====&lt;br /&gt;
This is worth 1 point out of the 5, but should probably be done as soon as you&lt;br /&gt;
can during Part III.&lt;br /&gt;
&lt;br /&gt;
Your RunLengthEncoding implementation is required to have a check() method,&lt;br /&gt;
which walks through the run-length encoding and checks its validity.&lt;br /&gt;
Specifically, it should print a warning message if any of the following&lt;br /&gt;
problems are found:&lt;br /&gt;
* If two consecutive runs have exactly the same type of contents.&amp;lt;br&amp;gt;For instance, an &amp;quot;F12&amp;quot; run followed by an &amp;quot;F8&amp;quot; run is illegal, because they should have been consolidated into a single run.  (Don't forget, though, that sharks are divided based on how recently they've eaten.)&lt;br /&gt;
* If the sum of all run lengths doesn't equal the size (in cells) of the Ocean; i.e. its width times its height.&lt;br /&gt;
&lt;br /&gt;
You may find that the check() method is very useful in helping to debug your&lt;br /&gt;
RunLengthEncoding constructors and addFish() and addShark() in Part IV.&lt;br /&gt;
&lt;br /&gt;
===Part IV:  Adding a Fish or Shark to a Run-Length Encoding===&lt;br /&gt;
&lt;br /&gt;
The last part is the hardest, but it is only worth 10% of the total score&lt;br /&gt;
(2 points out of 20), so don't panic if you can't finish it.&lt;br /&gt;
&lt;br /&gt;
Implement the addFish() and addShark() methods of the RunLengthEncoding class,&lt;br /&gt;
which are similar to the addFish() and addShark() methods of the Ocean class.&lt;br /&gt;
However, this code is much trickier to write.  Observe that addFish() and&lt;br /&gt;
addShark() can lengthen, or even shorten, an existing run-length encoding.  To&lt;br /&gt;
add a shark or fish to a run-length encoded ocean, you will need to find the&lt;br /&gt;
right run in the linked list, and perhaps break it apart into two or three&lt;br /&gt;
runs.  If the new shark or fish is adjacent to other sharks or fish, you should&lt;br /&gt;
consolidate runs to keep memory use down.  (Your check() method ensures that&lt;br /&gt;
your encoding is as compact as possible.)&lt;br /&gt;
&lt;br /&gt;
Your addFish() and addShark() routines should run in time proportional to the&lt;br /&gt;
number of runs in the encoding.  Therefore, you may not convert the run-length&lt;br /&gt;
encoding to an Ocean object, add the fish or shark to the Ocean, and then&lt;br /&gt;
convert back to a run-length encoding; that is much too slow.&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61b/Projects/Ocean&amp;diff=24418</id>
		<title>CS/61b/Projects/Ocean</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61b/Projects/Ocean&amp;diff=24418"/>
		<updated>2023-02-20T03:51:36Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61b/Projects/Ocean to Computer Science/61b/Projects/Ocean&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[Computer Science/61b/Projects/Ocean]]&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61b/Projects/Ocean/DList.java&amp;diff=24419</id>
		<title>Computer Science/61b/Projects/Ocean/DList.java</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61b/Projects/Ocean/DList.java&amp;diff=24419"/>
		<updated>2023-02-20T03:51:36Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61b/Projects/Ocean/DList.java to Computer Science/61b/Projects/Ocean/DList.java&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{code}}&lt;br /&gt;
 /* DList.java */&lt;br /&gt;
 &lt;br /&gt;
 /**&lt;br /&gt;
  *  The DList class is a doubly-linked implementation of the linked list&lt;br /&gt;
  *  abstraction.  DLists are mutable data structures, which can grow at either&lt;br /&gt;
  *  end.&lt;br /&gt;
  *&lt;br /&gt;
  *  This class is incomplete and only includes the methods necessary for the Oceans project&lt;br /&gt;
  **/&lt;br /&gt;
 &lt;br /&gt;
 public class DList {&lt;br /&gt;
 	private DListNode head;&lt;br /&gt;
 	// we have to make this non-private so that we can manipulate size directly when we call addShark() and addFish() on a RLE&lt;br /&gt;
 	// (at least it makes those manipulations easier)&lt;br /&gt;
 	int size;&lt;br /&gt;
 	// Ocean-specific fields&lt;br /&gt;
 	int dimx;&lt;br /&gt;
 	int dimy;&lt;br /&gt;
 	int starvetime;&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  DList() constructs an empty list.&lt;br /&gt;
 	 **/&lt;br /&gt;
 	&lt;br /&gt;
 	public DList() {&lt;br /&gt;
 		size = 0;&lt;br /&gt;
 		head = new DListNode();&lt;br /&gt;
 		head.next = head;&lt;br /&gt;
 		head.prev = head;&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 * Ocean-specific: constructs a new list representing an i by j ocean where sharks die according to starve&lt;br /&gt;
 	 * set size, dimx, and dimy appropriately; set starvetime to starve param&lt;br /&gt;
 	 **/&lt;br /&gt;
 	&lt;br /&gt;
 	public DList(int i, int j, int starve) {&lt;br /&gt;
 		size = 0;&lt;br /&gt;
 		head = new DListNode();&lt;br /&gt;
 		head.next = head;&lt;br /&gt;
 		head.prev = head;&lt;br /&gt;
 		dimx = i;&lt;br /&gt;
 		dimy = j;&lt;br /&gt;
 		starvetime = starve;&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  isEmpty() indicates whether the list is empty.&lt;br /&gt;
 	 *  @return true if the list is empty, false otherwise.&lt;br /&gt;
 	 **/&lt;br /&gt;
 	&lt;br /&gt;
 	public boolean isEmpty() {&lt;br /&gt;
 		return size == 0;&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  length() returns the length of this list.&lt;br /&gt;
 	 *  @return the length of this list.&lt;br /&gt;
 	 **/&lt;br /&gt;
 	&lt;br /&gt;
 	public int length() {&lt;br /&gt;
 		return size;&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  insertFront() inserts a block of cells at the beginning of this list.&lt;br /&gt;
 	 *  @param type the type of cell to be inserted.&lt;br /&gt;
 	 *	@param frequency the number of consecutive cells of this type&lt;br /&gt;
 	 **/&lt;br /&gt;
 	&lt;br /&gt;
 	public void insertFront(int type, int frequency, int hunger) {&lt;br /&gt;
 		DListNode item = new DListNode(type);&lt;br /&gt;
 		head.next.prev = item;&lt;br /&gt;
 		item.next = head.next;&lt;br /&gt;
 		item.prev = head;&lt;br /&gt;
 		head.next = item;&lt;br /&gt;
 		item.consecs = frequency;&lt;br /&gt;
 		item.hunger = hunger;&lt;br /&gt;
 		size++;&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  insertEnd() inserts item &amp;quot;obj&amp;quot; at the end of this list.&lt;br /&gt;
 	 *  @param type the type of cell to be inserted.&lt;br /&gt;
 	 *	@param frequency the number of consecutive cells of this type&lt;br /&gt;
 	 **/&lt;br /&gt;
 	&lt;br /&gt;
 	public void insertEnd(int type, int frequency, int hunger) {&lt;br /&gt;
 		DListNode item = new DListNode(type);&lt;br /&gt;
 		head.prev.next = item;&lt;br /&gt;
 		item.next = head;&lt;br /&gt;
 		item.prev = head.prev;&lt;br /&gt;
 		head.prev = item;&lt;br /&gt;
 		item.consecs = frequency;&lt;br /&gt;
 		item.hunger = hunger;&lt;br /&gt;
 		size++;&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	public void insertEnd(int type, int frequency) {&lt;br /&gt;
 		insertEnd(type, frequency, 0);&lt;br /&gt;
 	}&lt;br /&gt;
 &lt;br /&gt;
 	public void insertFront(int type, int frequency) {&lt;br /&gt;
 		insertFront(type, frequency, 0);&lt;br /&gt;
 	}&lt;br /&gt;
 &lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  nth() returns the NODE at the specified position.  If position &amp;lt; 1 or&lt;br /&gt;
 	 *  position &amp;gt; this.length(), null is returned.  Otherwise, the item at&lt;br /&gt;
 	 *  position &amp;quot;position&amp;quot; is returned.  The list does not change.&lt;br /&gt;
 	 *  @param position the desired position, from 1 to length(), in the list.&lt;br /&gt;
 	 *  @return the NODE at the given position in the list - this allows us to call .next and .prev on the returned value&lt;br /&gt;
 	 **/&lt;br /&gt;
 	&lt;br /&gt;
 	public DListNode nth(int position) {&lt;br /&gt;
 		DListNode currentNode;&lt;br /&gt;
 		if ((position &amp;lt; 1) || (head.next == head)) {&lt;br /&gt;
 			return null;&lt;br /&gt;
 		} else {&lt;br /&gt;
 			currentNode = head.next;&lt;br /&gt;
 			while (position &amp;gt; 1) {&lt;br /&gt;
 				currentNode = currentNode.next;&lt;br /&gt;
 				if (currentNode == head) {&lt;br /&gt;
 					return null;&lt;br /&gt;
 				}&lt;br /&gt;
 				position--;&lt;br /&gt;
 			}&lt;br /&gt;
 			return currentNode;&lt;br /&gt;
 		}&lt;br /&gt;
 	}&lt;br /&gt;
 }&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61b/Projects/Ocean/DList.java&amp;diff=24420</id>
		<title>CS/61b/Projects/Ocean/DList.java</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61b/Projects/Ocean/DList.java&amp;diff=24420"/>
		<updated>2023-02-20T03:51:36Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61b/Projects/Ocean/DList.java to Computer Science/61b/Projects/Ocean/DList.java&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[Computer Science/61b/Projects/Ocean/DList.java]]&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61b/Projects/Ocean/DListNode.java&amp;diff=24421</id>
		<title>Computer Science/61b/Projects/Ocean/DListNode.java</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61b/Projects/Ocean/DListNode.java&amp;diff=24421"/>
		<updated>2023-02-20T03:51:36Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61b/Projects/Ocean/DListNode.java to Computer Science/61b/Projects/Ocean/DListNode.java&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{code}}&lt;br /&gt;
 /* DListNode.java */&lt;br /&gt;
 &lt;br /&gt;
 /**&lt;br /&gt;
  *  DListNode is a class used internally by the DList class.  A DList object&lt;br /&gt;
  *  is a doubly-linked list, and a DListNode is a node of a doubly-linked&lt;br /&gt;
  *  list.  Each DListNode normally has three references:  one to an object, one to&lt;br /&gt;
  *  the next node in the list, and another to the previous node in the list.&lt;br /&gt;
  *&lt;br /&gt;
  * However, for purposes of the Ocean project this is changed as follows:&lt;br /&gt;
  *   The item field is actually named type to better reflect the data that it holds&lt;br /&gt;
  *   Consequently, the types are all ints and not objects&lt;br /&gt;
  *   The number of fields is FIVE and not three - an additional field is added for the number of consecutive&lt;br /&gt;
  *   cells of the given type and another for the shark's current hunger&lt;br /&gt;
  *&lt;br /&gt;
  */&lt;br /&gt;
 &lt;br /&gt;
 class DListNode {&lt;br /&gt;
 	int type;&lt;br /&gt;
 	int hunger;&lt;br /&gt;
 	int consecs;&lt;br /&gt;
 	DListNode next;&lt;br /&gt;
 	DListNode prev;&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  DListNode() (with two parameters) constructs a list node referencing the&lt;br /&gt;
 	 *  item &amp;quot;obj&amp;quot;, whose next list node is to be &amp;quot;next&amp;quot;.&lt;br /&gt;
 	 */&lt;br /&gt;
 	&lt;br /&gt;
 	DListNode(int type, int hunger, DListNode next) {&lt;br /&gt;
 		this.type = type;&lt;br /&gt;
 		this.hunger = hunger;&lt;br /&gt;
 		this.next = next;&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	DListNode(int type, DListNode next) {&lt;br /&gt;
 		this(type, 0, next);&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	DListNode(int type, int hunger) {&lt;br /&gt;
 		this(type, hunger, null);&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  DListNode() (with one parameter) constructs a list node referencing the&lt;br /&gt;
 	 *  item &amp;quot;obj&amp;quot;.&lt;br /&gt;
 	 **/&lt;br /&gt;
 	&lt;br /&gt;
 	DListNode(int type) {&lt;br /&gt;
 		this(type, null);&lt;br /&gt;
 	}&lt;br /&gt;
 &lt;br /&gt;
 	DListNode() {&lt;br /&gt;
 		this(Ocean.EMPTY, null);&lt;br /&gt;
 	}&lt;br /&gt;
 }&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61b/Projects/Ocean/DListNode.java&amp;diff=24422</id>
		<title>CS/61b/Projects/Ocean/DListNode.java</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61b/Projects/Ocean/DListNode.java&amp;diff=24422"/>
		<updated>2023-02-20T03:51:36Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61b/Projects/Ocean/DListNode.java to Computer Science/61b/Projects/Ocean/DListNode.java&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[Computer Science/61b/Projects/Ocean/DListNode.java]]&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61b/Projects/Ocean/Ocean.java&amp;diff=24423</id>
		<title>Computer Science/61b/Projects/Ocean/Ocean.java</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61b/Projects/Ocean/Ocean.java&amp;diff=24423"/>
		<updated>2023-02-20T03:51:36Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61b/Projects/Ocean/Ocean.java to Computer Science/61b/Projects/Ocean/Ocean.java&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{code}}&lt;br /&gt;
 /* Ocean.java */&lt;br /&gt;
 &lt;br /&gt;
 /**&lt;br /&gt;
  *  The Ocean class defines an object that models an ocean full of sharks and&lt;br /&gt;
  *  fish.  Descriptions of the methods you must implement appear below.  They&lt;br /&gt;
  *  include a constructor of the form&lt;br /&gt;
  *&lt;br /&gt;
  *      public Ocean(int i, int j, int starveTime);&lt;br /&gt;
  *&lt;br /&gt;
  *  that creates an empty ocean having width i and height j, in which sharks&lt;br /&gt;
  *  starve after starveTime timesteps.&lt;br /&gt;
  *&lt;br /&gt;
  *  See the README file accompanying this project for additional details.&lt;br /&gt;
  */&lt;br /&gt;
 &lt;br /&gt;
 public class Ocean {&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	*  Do not rename these constants.  WARNING:  if you change the numbers, you&lt;br /&gt;
 	*  will need to recompile Test4.java.  Failure to do so will give you a very&lt;br /&gt;
 	*  hard-to-find bug.&lt;br /&gt;
 	*/&lt;br /&gt;
 	&lt;br /&gt;
 	public final static int EMPTY = 0;&lt;br /&gt;
 	public final static int SHARK = 1;&lt;br /&gt;
 	public final static int FISH = 2;&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	*  Define any variables associated with an Ocean object here.  These&lt;br /&gt;
 	*  variables MUST be private.&lt;br /&gt;
 	*/&lt;br /&gt;
 	&lt;br /&gt;
 	private int x;&lt;br /&gt;
 	private int y;&lt;br /&gt;
 	private int starvetime;&lt;br /&gt;
 	private int[] cells;&lt;br /&gt;
 	private int[] hunger;&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  The following methods are required for Part I.&lt;br /&gt;
 	 */&lt;br /&gt;
 	&lt;br /&gt;
 	/** &lt;br /&gt;
 		* Given an x &amp;amp; y coordinate, returns the cell's index in an ocean array&lt;br /&gt;
 		* if either coordinate is out of bounds due to the ocean's size, convert it accordingly&lt;br /&gt;
 		* @param x is the x-coord; @param y is the y-coord of the cell&lt;br /&gt;
 		* @return the index in the array&lt;br /&gt;
 		**/&lt;br /&gt;
 	public int cellind(int x, int y) {&lt;br /&gt;
 		x = x%this.x; //  Math.abs(x)%this.x; gives incorrect values&lt;br /&gt;
 		y = y%this.y;&lt;br /&gt;
 		if (x &amp;lt; 0) { x = x+this.x; }&lt;br /&gt;
 		if (y &amp;lt; 0) { y = y+this.y; }&lt;br /&gt;
 		int ind = this.x*y+x;&lt;br /&gt;
 		return ind;&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	/** @param pos is the index in the ocean array&lt;br /&gt;
 		the methods below convert an array index into an x and y coordinate, respectively **/&lt;br /&gt;
 	&lt;br /&gt;
 	public int coordx(int pos) {&lt;br /&gt;
 		int i = pos%x;&lt;br /&gt;
 		return i; }&lt;br /&gt;
   	&lt;br /&gt;
 	public int coordy(int pos) {&lt;br /&gt;
 		int j = pos/x;&lt;br /&gt;
 		return j; }&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  Ocean() is a constructor that creates an empty ocean having width i and&lt;br /&gt;
 	 *  height j, in which sharks starve after starveTime timesteps.&lt;br /&gt;
 	 *  @param i is the width of the ocean.&lt;br /&gt;
 	 *  @param j is the height of the ocean.&lt;br /&gt;
 	 *  @param starveTime is the number of timesteps sharks survive without food.&lt;br /&gt;
 	 */&lt;br /&gt;
 	&lt;br /&gt;
 	public Ocean(int i, int j, int starveTime) {&lt;br /&gt;
 		x = i;&lt;br /&gt;
 		y = j;&lt;br /&gt;
 		starvetime = starveTime;&lt;br /&gt;
 		cells = new int[i*j];&lt;br /&gt;
 		for (int ic=0; ic&amp;lt;cells.length; ic++) { cells[ic] = EMPTY; } // all cells EMPTY by default&lt;br /&gt;
 		hunger = new int[i*j];&lt;br /&gt;
 		for (int ih=0; ih&amp;lt;hunger.length; ih++) { hunger[ih] = 0; } // hunger of all cells 0 by default&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  width() returns the width of an Ocean object.&lt;br /&gt;
 	 *  @return the width of the ocean.&lt;br /&gt;
 	 */&lt;br /&gt;
 	&lt;br /&gt;
 	public int width() {&lt;br /&gt;
 		return x;&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  height() returns the height of an Ocean object.&lt;br /&gt;
 	 *  @return the height of the ocean.&lt;br /&gt;
 	 */&lt;br /&gt;
 	&lt;br /&gt;
 	public int height() {&lt;br /&gt;
 		return y;&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  starveTime() returns the number of timesteps sharks survive without food.&lt;br /&gt;
 	 *  @return the number of timesteps sharks survive without food.&lt;br /&gt;
 	 */&lt;br /&gt;
 	&lt;br /&gt;
 	public int starveTime() {&lt;br /&gt;
 		return starvetime;&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  addFish() places a fish in cell (x, y) if the cell is empty.  If the&lt;br /&gt;
 	 *  cell is already occupied, leave the cell as it is.&lt;br /&gt;
 	 *  @param x is the x-coordinate of the cell to place a fish in.&lt;br /&gt;
 	 *  @param y is the y-coordinate of the cell to place a fish in.&lt;br /&gt;
 	 */&lt;br /&gt;
 	&lt;br /&gt;
 	public void addFish(int x, int y) {&lt;br /&gt;
 		if (cells[this.cellind(x,y)] == EMPTY) {&lt;br /&gt;
 			cells[this.cellind(x,y)] = FISH;&lt;br /&gt;
 		}&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  addShark() (with two parameters) places a newborn shark in cell (x, y) if&lt;br /&gt;
 	 *  the cell is empty.  A &amp;quot;newborn&amp;quot; shark is equivalent to a shark that has&lt;br /&gt;
 	 *  just eaten.  If the cell is already occupied, leave the cell as it is.&lt;br /&gt;
 	 *  @param x is the x-coordinate of the cell to place a shark in.&lt;br /&gt;
 	 *  @param y is the y-coordinate of the cell to place a shark in.&lt;br /&gt;
 	 */&lt;br /&gt;
 	&lt;br /&gt;
 	public void addShark(int x, int y) {&lt;br /&gt;
 		int curpos = this.cellind(x,y);&lt;br /&gt;
 		if (cells[curpos] == EMPTY) {&lt;br /&gt;
 			cells[curpos] = SHARK;&lt;br /&gt;
 			hunger[curpos] = starvetime;&lt;br /&gt;
 		}&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  cellContents() returns EMPTY if cell (x, y) is empty, FISH if it contains&lt;br /&gt;
 	 *  a fish, and SHARK if it contains a shark.&lt;br /&gt;
 	 *  @param x is the x-coordinate of the cell whose contents are queried.&lt;br /&gt;
 	 *  @param y is the y-coordinate of the cell whose contents are queried.&lt;br /&gt;
 	 */&lt;br /&gt;
 	&lt;br /&gt;
 	public int cellContents(int x, int y) {&lt;br /&gt;
 		return cells[this.cellind(x,y)]; // simply return the contents at the given index&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  timeStep() performs a simulation timestep as described in README.&lt;br /&gt;
 	 *  @return an ocean representing the elapse of one timestep.&lt;br /&gt;
 	 * required actions:&lt;br /&gt;
 	 *  1) If a cell contains a shark, and any of its neighbors is a fish, then the&lt;br /&gt;
 	 *  shark eats during the timestep, and it remains in the cell at the end of the&lt;br /&gt;
 	 *  timestep.  (We may have multiple sharks sharing the same fish.  This is fine;&lt;br /&gt;
 	 *  they all get enough to eat.)   &lt;br /&gt;
 	 *  &lt;br /&gt;
 	 *  2) If a cell contains a shark, and none of its neighbors is a fish, it gets&lt;br /&gt;
 	 *  hungrier during the timestep.  If this timestep is the (starveTime + 1)th&lt;br /&gt;
 	 *  timestep the shark has gone through without eating, then the shark dies&lt;br /&gt;
 	 *  (disappears).  Otherwise, it remains in the cell.  An example demonstrating&lt;br /&gt;
 	 *  this rule appears below.   &lt;br /&gt;
 	 *  &lt;br /&gt;
 	 *  3) If a cell contains a fish, and all of its neighbors are either empty or are&lt;br /&gt;
 	 *  other fish, then the fish stays where it is.   &lt;br /&gt;
 	 *&lt;br /&gt;
 	 *  4) If a cell contains a fish, and one of its neighbors is a shark, then the&lt;br /&gt;
 	 *  fish is eaten by a shark, and therefore disappears.   &lt;br /&gt;
 	 *  &lt;br /&gt;
 	 *  5) If a cell contains a fish, and two or more of its neighbors are sharks, then&lt;br /&gt;
 	 *  a new shark is born in that cell.  Sharks are well-fed at birth; _after_ they&lt;br /&gt;
 	 *  are born, they can survive an additional starveTime timesteps without eating.&lt;br /&gt;
 	 *  (But they will die at the end of starveTime + 1 consecutive timesteps without&lt;br /&gt;
 	 *  eating.)  &lt;br /&gt;
 	 *  &lt;br /&gt;
 	 *  6) If a cell is empty, and fewer than two of its neighbors are fish, then the&lt;br /&gt;
 	 *  cell remains empty.&lt;br /&gt;
 	 *  &lt;br /&gt;
 	 *  7) If a cell is empty, at least two of its neighbors are fish, and at most one&lt;br /&gt;
 	 *  of its neighbors is a shark, then a new fish is born in that cell.&lt;br /&gt;
 	 *    &lt;br /&gt;
 	 *  8) If a cell is empty, at least two of its neighbors are fish, and at least two&lt;br /&gt;
 	 *  of its neighbors are sharks, then a new shark is born in that cell.  (The new&lt;br /&gt;
 	 *  shark is well-fed at birth, even though it hasn't eaten a fish yet.)&lt;br /&gt;
 	 */&lt;br /&gt;
 	&lt;br /&gt;
 	/** @return an array of neighbors around a given position **/&lt;br /&gt;
 	public int[] neighborarray(int pos) {&lt;br /&gt;
 		int[] array = new int[8];&lt;br /&gt;
 		int x = coordx(pos);&lt;br /&gt;
 		int y = coordy(pos);&lt;br /&gt;
 		array[0] = cellContents(x-1, y-1); // nw&lt;br /&gt;
 		array[1] = cellContents(x, y-1); // n&lt;br /&gt;
 		array[2] = cellContents(x+1, y-1); // ne&lt;br /&gt;
 		array[3] = cellContents(x+1, y); // e&lt;br /&gt;
 		array[4] = cellContents(x+1, y+1); // se&lt;br /&gt;
 		array[5] = cellContents(x, y+1); // s&lt;br /&gt;
 		array[6] = cellContents(x-1, y+1); // sw&lt;br /&gt;
 		array[7] = cellContents(x-1, y); // w&lt;br /&gt;
 		return array; }&lt;br /&gt;
 	&lt;br /&gt;
 	/** @return the number of neighbors of a given type around a given position **/&lt;br /&gt;
 	public int neighbor(int type, int pos) {&lt;br /&gt;
 		int[] array = neighborarray(pos);&lt;br /&gt;
 		int number = 0;&lt;br /&gt;
 		for (int i=0; i&amp;lt;array.length; i++) {&lt;br /&gt;
 			if (array[i] == type) { number++; } }&lt;br /&gt;
 		return number; }&lt;br /&gt;
 	&lt;br /&gt;
 	/** @return true if the method name's condition is satisfied around for a given position **/&lt;br /&gt;
 	public boolean caneat(int pos) { // 1 - If a cell contains a shark, and any of its neighbors is a fish&lt;br /&gt;
 		if (cells[pos] == SHARK &amp;amp;&amp;amp; neighbor(FISH, pos)&amp;gt;0) {&lt;br /&gt;
 			return true;&lt;br /&gt;
 		} else { return false; } }&lt;br /&gt;
 	&lt;br /&gt;
 	public boolean dangerous(int pos) { // 4 - If a cell contains a fish, and one of its neighbors is a shark&lt;br /&gt;
 		if (cells[pos] == FISH &amp;amp;&amp;amp; neighbor(SHARK, pos)==1) {&lt;br /&gt;
 			return true;&lt;br /&gt;
 		} else { return false; } }&lt;br /&gt;
    	&lt;br /&gt;
 	public boolean givesbirth(int pos) { /* 5 - If a cell contains a fish, and two or more of its neighbors are sharks&lt;br /&gt;
    		8 - If a cell is empty, at least two of its neighbors are fish, and at least two of its neighbors are sharks */&lt;br /&gt;
 		if (cells[pos] == FISH &amp;amp;&amp;amp; neighbor(SHARK, pos)&amp;gt;1) {&lt;br /&gt;
 			return true;&lt;br /&gt;
 		} else if (cells[pos] == EMPTY &amp;amp;&amp;amp; neighbor(FISH, pos)&amp;gt;1 &amp;amp;&amp;amp; neighbor(SHARK, pos)&amp;gt;1) {&lt;br /&gt;
 			return true;&lt;br /&gt;
 		} else { return false; } }&lt;br /&gt;
    	&lt;br /&gt;
 	public boolean spawnsfish(int pos) { // 7 - If a cell is empty, at least two of its neighbors are fish, and at most one of its neighbors is a shark&lt;br /&gt;
 		if (cells[pos] == EMPTY &amp;amp;&amp;amp; neighbor(FISH, pos)&amp;gt;1 &amp;amp;&amp;amp; neighbor(SHARK, pos)&amp;lt;2) {&lt;br /&gt;
 			return true;&lt;br /&gt;
 		} else { return false; } }&lt;br /&gt;
 	&lt;br /&gt;
 	public Ocean timeStep() {&lt;br /&gt;
 		Ocean newocean = new Ocean(x, y, starvetime); // create new Ocean to hold the state after timeStep&lt;br /&gt;
 		/** Important notes: this new ocean is initially &amp;quot;blank&amp;quot;. What this means here:&lt;br /&gt;
 		  * If someone &amp;quot;dies&amp;quot; below, we don't need to do anything, because the cell in the new ocean is already EMPTY&lt;br /&gt;
 		  * If any other values (i.e. hunger) change, they need to be written to the new ocean&lt;br /&gt;
 		  * If the value of a given cell does not change, it MUST be copied to the new ocean&lt;br /&gt;
 		**/&lt;br /&gt;
 		for (int pos=0; pos&amp;lt;cells.length; pos++) {&lt;br /&gt;
 			if (caneat(pos)) {  // the shark eats during the timestep, and it remains in the cell at the end of the timestep&lt;br /&gt;
 				newocean.cells[pos] = SHARK;&lt;br /&gt;
 				newocean.hunger[pos] = starvetime; }&lt;br /&gt;
 			else if (caneat(pos) != true &amp;amp;&amp;amp; cells[pos]==SHARK) {&lt;br /&gt;
 				if (hunger[pos] == 0) { /* If this timestep is the (starveTime + 1)th timestep&lt;br /&gt;
 					the shark has gone through without eating&lt;br /&gt;
 					then the shark dies (disappears), so we do nothing since value is EMPTY by default */&lt;br /&gt;
 				} else { // otherwise decrease its turns to die by 1&lt;br /&gt;
 					newocean.cells[pos] = SHARK;&lt;br /&gt;
 					newocean.hunger[pos] = hunger[pos] - 1;&lt;br /&gt;
 				}&lt;br /&gt;
 			} else if (dangerous(pos)) { /* the fish is eaten by a shark and disappears, so do nothing */&lt;br /&gt;
 			} else if (givesbirth(pos)) {  // a new shark is born in that cell; (sharks are well-fed at birth)&lt;br /&gt;
 				newocean.cells[pos] = SHARK;&lt;br /&gt;
 				newocean.hunger[pos] = starvetime;&lt;br /&gt;
 			} else if (spawnsfish(pos)) { newocean.cells[pos] = FISH;  // a new fish is born in that cell&lt;br /&gt;
 			} else { newocean.cells[pos] = cells[pos]; } // in all other cases, just copy the existing value - CRUCIAL!&lt;br /&gt;
 			/** 3 - If a cell contains a fish, and all of its neighbors are either empty or are other fish, then the fish stays where it is.&lt;br /&gt;
 			if (pos.boring) {  }&lt;br /&gt;
 			6 - If a cell is empty, and fewer than two of its neighbors are fish, then the cell remains empty.&lt;br /&gt;
 			if (pos.fishy) {  }&lt;br /&gt;
 			**/&lt;br /&gt;
 		}&lt;br /&gt;
 		return newocean; // return the newly-created and modified ocean&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 /**&lt;br /&gt;
  *  The following method is required for Part II.&lt;br /&gt;
  */&lt;br /&gt;
 &lt;br /&gt;
 /**&lt;br /&gt;
  *  addShark() (with three parameters) places a shark in cell (x, y) if the&lt;br /&gt;
  *  cell is empty.  The shark's hunger is represented by the third parameter.&lt;br /&gt;
  *  If the cell is already occupied, leave the cell as it is.  You will need&lt;br /&gt;
  *  this method to help convert run-length encodings to Oceans.&lt;br /&gt;
  *  @param x is the x-coordinate of the cell to place a shark in.&lt;br /&gt;
  *  @param y is the y-coordinate of the cell to place a shark in.&lt;br /&gt;
  *  @param feeding is an integer that indicates the shark's hunger.  You may&lt;br /&gt;
  *  encode it any way you want; for instance, &amp;quot;feeding&amp;quot; may be the&lt;br /&gt;
  *  last timestep the shark was fed, or the amount of time that has&lt;br /&gt;
  *  passed since the shark was last fed, or the amount of time left&lt;br /&gt;
  *  before the shark will starve.  It's up to you, but be consistent.&lt;br /&gt;
  */&lt;br /&gt;
 &lt;br /&gt;
 	public void addShark(int x, int y, int feeding) {&lt;br /&gt;
 		int curpos = this.cellind(x,y);&lt;br /&gt;
 		if	(cells[curpos] == EMPTY) {&lt;br /&gt;
 			cells[curpos] = SHARK;&lt;br /&gt;
 			hunger[curpos] = feeding;&lt;br /&gt;
 		}&lt;br /&gt;
 	}&lt;br /&gt;
 					 &lt;br /&gt;
 /**&lt;br /&gt;
  *  The following method is required for Part III.&lt;br /&gt;
  */&lt;br /&gt;
 &lt;br /&gt;
 /**&lt;br /&gt;
  *  sharkFeeding() returns an integer that indicates the hunger of the shark&lt;br /&gt;
  *  in cell (x, y), using the same &amp;quot;feeding&amp;quot; representation as the parameter&lt;br /&gt;
  *  to addShark() described above.  If cell (x, y) does not contain a shark,&lt;br /&gt;
  *  then its return value is undefined--that is, anything you want.&lt;br /&gt;
  *  Normally, this method should not be called if cell (x, y) does not&lt;br /&gt;
  *  contain a shark.  You will need this method to help convert Oceans to&lt;br /&gt;
  *  run-length encodings.&lt;br /&gt;
  *  @param x is the x-coordinate of the cell whose contents are queried.&lt;br /&gt;
  *  @param y is the y-coordinate of the cell whose contents are queried.&lt;br /&gt;
  */&lt;br /&gt;
 &lt;br /&gt;
 	public int sharkFeeding(int x, int y) {&lt;br /&gt;
 		return hunger[this.cellind(x,y)];&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	/* The method below does the same thing as above, but takes an array position instead of (x,y) coords */&lt;br /&gt;
 	&lt;br /&gt;
 	public int sharkFeeding(int pos) {&lt;br /&gt;
 		return sharkFeeding(coordx(pos), coordy(pos));&lt;br /&gt;
 	}&lt;br /&gt;
 &lt;br /&gt;
 }&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61b/Projects/Ocean/Ocean.java&amp;diff=24424</id>
		<title>CS/61b/Projects/Ocean/Ocean.java</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=CS/61b/Projects/Ocean/Ocean.java&amp;diff=24424"/>
		<updated>2023-02-20T03:51:36Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61b/Projects/Ocean/Ocean.java to Computer Science/61b/Projects/Ocean/Ocean.java&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[Computer Science/61b/Projects/Ocean/Ocean.java]]&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
	<entry>
		<id>http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61b/Projects/Ocean/RunLengthEncoding.java&amp;diff=24425</id>
		<title>Computer Science/61b/Projects/Ocean/RunLengthEncoding.java</title>
		<link rel="alternate" type="text/html" href="http://www.lensovet.net/~sysadmin/w/index.php?title=Computer_Science/61b/Projects/Ocean/RunLengthEncoding.java&amp;diff=24425"/>
		<updated>2023-02-20T03:51:36Z</updated>

		<summary type="html">&lt;p&gt;Lensovet: Lensovet moved page CS/61b/Projects/Ocean/RunLengthEncoding.java to Computer Science/61b/Projects/Ocean/RunLengthEncoding.java&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{code}}&lt;br /&gt;
 /* RunLengthEncoding.java */&lt;br /&gt;
 &lt;br /&gt;
 /**&lt;br /&gt;
  *  The RunLengthEncoding class defines an object that run-length encodes an&lt;br /&gt;
  *  Ocean object.  Descriptions of the methods you must implement appear below.&lt;br /&gt;
  *  They include constructors of the form&lt;br /&gt;
  *&lt;br /&gt;
  *      public RunLengthEncoding(int i, int j, int starveTime);&lt;br /&gt;
  *      public RunLengthEncoding(int i, int j, int starveTime,&lt;br /&gt;
  *                               int[] runTypes, int[] runLengths) {&lt;br /&gt;
  *      public RunLengthEncoding(Ocean ocean) {&lt;br /&gt;
  *&lt;br /&gt;
  *  that create a run-length encoding of an Ocean having width i and height j,&lt;br /&gt;
  *  in which sharks starve after starveTime timesteps.&lt;br /&gt;
  *&lt;br /&gt;
  *  The first constructor creates a run-length encoding of an Ocean in which&lt;br /&gt;
  *  every cell is empty.  The second constructor creates a run-length encoding&lt;br /&gt;
  *  for which the runs are provided as parameters.  The third constructor&lt;br /&gt;
  *  converts an Ocean object into a run-length encoding of that object.&lt;br /&gt;
  *&lt;br /&gt;
  *  See the README file accompanying this project for additional details.&lt;br /&gt;
  **/&lt;br /&gt;
 &lt;br /&gt;
 public class RunLengthEncoding {&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  Define any variables associated with a RunLengthEncoding object here.&lt;br /&gt;
 	 *  These variables MUST be private.&lt;br /&gt;
 	 **/&lt;br /&gt;
 	&lt;br /&gt;
 	// since this uses a separate doubly-linked list class, most fields are already defined there&lt;br /&gt;
 	private int runsleft;&lt;br /&gt;
 	private DList rle;&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  The following methods are required for Part II.&lt;br /&gt;
 	 **/&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  RunLengthEncoding() (with three parameters) is a constructor that creates&lt;br /&gt;
 	 *  a run-length encoding of an empty ocean having width i and height j,&lt;br /&gt;
 	 *  in which sharks starve after starveTime timesteps.&lt;br /&gt;
 	 *  @param i is the width of the ocean.&lt;br /&gt;
 	 *  @param j is the height of the ocean.&lt;br /&gt;
 	 *  @param starveTime is the number of timesteps sharks survive without food.&lt;br /&gt;
 	 **/&lt;br /&gt;
 	&lt;br /&gt;
 	public RunLengthEncoding(int i, int j, int starveTime) {&lt;br /&gt;
 		rle = new DList(i, j, starveTime);&lt;br /&gt;
 		rle.insertFront(Ocean.EMPTY, i*j);&lt;br /&gt;
 		runsleft = 1;&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  RunLengthEncoding() (with five parameters) is a constructor that creates&lt;br /&gt;
 	 *  a run-length encoding of an ocean having width i and height j, in which&lt;br /&gt;
 	 *  sharks starve after starveTime timesteps.  The runs of the run-length&lt;br /&gt;
 	 *  encoding are taken from two input arrays.  Run i has length runLengths[i]&lt;br /&gt;
 	 *  and species runTypes[i].&lt;br /&gt;
 	 *  @param i is the width of the ocean.&lt;br /&gt;
 	 *  @param j is the height of the ocean.&lt;br /&gt;
 	 *  @param starveTime is the number of timesteps sharks survive without food.&lt;br /&gt;
 	 *  @param runTypes is an array that represents the species represented by&lt;br /&gt;
 	 *         each run.  Each element of runTypes is Ocean.EMPTY, Ocean.FISH,&lt;br /&gt;
 	 *         or Ocean.SHARK.  Any run of sharks is treated as a run of newborn&lt;br /&gt;
 	 *         sharks (which are equivalent to sharks that have just eaten).&lt;br /&gt;
 	 *  @param runLengths is an array that represents the length of each run.&lt;br /&gt;
 	 *         The sum of all elements of the runLengths array should be i * j.&lt;br /&gt;
 	 */&lt;br /&gt;
 	&lt;br /&gt;
 	public RunLengthEncoding(int i, int j, int starveTime,&lt;br /&gt;
 							 int[] runTypes, int[] runLengths) {&lt;br /&gt;
 		rle = new DList(i, j, starveTime);&lt;br /&gt;
 		if (runTypes.length != runLengths.length) { System.out.println(&amp;quot;INCOMPATIBLE ARRAYS&amp;quot;);&lt;br /&gt;
 		} else {&lt;br /&gt;
 			for (int ii = runTypes.length-1; ii&amp;gt;=0; ii--) {&lt;br /&gt;
 				if (runTypes[ii] == Ocean.SHARK) {&lt;br /&gt;
 					rle.insertFront(runTypes[ii], runLengths[ii], starveTime);&lt;br /&gt;
 				} else {&lt;br /&gt;
 					rle.insertFront(runTypes[ii], runLengths[ii]);&lt;br /&gt;
 				}&lt;br /&gt;
 			}&lt;br /&gt;
 			runsleft = runTypes.length;&lt;br /&gt;
 		}&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  restartRuns() and nextRun() are two methods that work together to return&lt;br /&gt;
 	 *  all the runs in the run-length encoding, one by one.  Each time&lt;br /&gt;
 	 *  nextRun() is invoked, it returns a different run (represented as a&lt;br /&gt;
 	 *  TypeAndSize object), until every run has been returned.  The first time&lt;br /&gt;
 	 *  nextRun() is invoked, it returns the first run in the encoding, which&lt;br /&gt;
 	 *  contains cell (0, 0).  After every run has been returned, nextRun()&lt;br /&gt;
 	 *  returns null, which lets the calling program know that there are no more&lt;br /&gt;
 	 *  runs in the encoding.&lt;br /&gt;
 	 *&lt;br /&gt;
 	 *  The restartRuns() method resets the enumeration, so that nextRun() will&lt;br /&gt;
 	 *  once again enumerate all the runs as if nextRun() were being invoked for&lt;br /&gt;
 	 *  the first time.&lt;br /&gt;
 	 *&lt;br /&gt;
 	 *  (Note:  Don't worry about what might happen if nextRun() is interleaved&lt;br /&gt;
 	 *  with addFish() or addShark(); it won't happen.)&lt;br /&gt;
 	 */&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  restartRuns() resets the enumeration as described above, so that&lt;br /&gt;
 	 *  nextRun() will enumerate all the runs from the beginning.&lt;br /&gt;
 	 */&lt;br /&gt;
 	&lt;br /&gt;
 	public void restartRuns() {&lt;br /&gt;
 		runsleft = rle.length();&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  nextRun() returns the next run in the enumeration, as described above.&lt;br /&gt;
 	 *  If the runs have been exhausted, it returns null.  The return value is&lt;br /&gt;
 	 *  a TypeAndSize object, which is nothing more than a way to return two&lt;br /&gt;
 	 *  integers at once.&lt;br /&gt;
 	 *  @return the next run in the enumeration, represented by a TypeAndSize object.&lt;br /&gt;
 	 */&lt;br /&gt;
 	&lt;br /&gt;
 	public TypeAndSize nextRun() {&lt;br /&gt;
 		if (runsleft == 0) { return null; }&lt;br /&gt;
 		else {&lt;br /&gt;
 			int curindex = rle.length()-runsleft+1;&lt;br /&gt;
 			DListNode curnode = rle.nth(curindex);&lt;br /&gt;
 			int tip = curnode.type;&lt;br /&gt;
 			int freq = curnode.consecs;&lt;br /&gt;
 			runsleft--;&lt;br /&gt;
 			return new TypeAndSize(tip, freq); }&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  toOcean() converts a run-length encoding of an ocean into an Ocean&lt;br /&gt;
 	 *  object.  You will need to implement the three-parameter addShark method&lt;br /&gt;
 	 *  in the Ocean class for this method's use.&lt;br /&gt;
 	 *  @return the Ocean represented by a run-length encoding.&lt;br /&gt;
 	 */&lt;br /&gt;
 	&lt;br /&gt;
 	public Ocean toOcean() {&lt;br /&gt;
 		int index = 0;&lt;br /&gt;
 		Ocean newocean = new Ocean(rle.dimx, rle.dimy, rle.starvetime);&lt;br /&gt;
 		for (int il = 1; il&amp;lt;=rle.length(); il++) { // walks through each node in the rle list&lt;br /&gt;
 			DListNode curnode = rle.nth(il);&lt;br /&gt;
 			int tip = curnode.type;&lt;br /&gt;
 			int freq = curnode.consecs;&lt;br /&gt;
 			int hunger = curnode.hunger;&lt;br /&gt;
 			int ia = index;&lt;br /&gt;
 			for (; ia &amp;lt; index+freq; ia++) {&lt;br /&gt;
 				if (tip == Ocean.SHARK) {&lt;br /&gt;
 					newocean.addShark(newocean.coordx(ia), newocean.coordy(ia), hunger);&lt;br /&gt;
 				} else if (tip == Ocean.FISH) {&lt;br /&gt;
 					newocean.addFish(newocean.coordx(ia), newocean.coordy(ia));&lt;br /&gt;
 				} else { } // do nothing, the cell is already EMPTY&lt;br /&gt;
 			}&lt;br /&gt;
 			index = ia;&lt;br /&gt;
 		}&lt;br /&gt;
 		return newocean;&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  The following method is required for Part III.&lt;br /&gt;
 	 */&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  RunLengthEncoding() (with one parameter) is a constructor that creates&lt;br /&gt;
 	 *  a run-length encoding of an input Ocean.  You will need to implement&lt;br /&gt;
 	 *  the sharkFeeding method in the Ocean class for this constructor's use.&lt;br /&gt;
 	 *  @param sea is the ocean to encode.&lt;br /&gt;
 	 */&lt;br /&gt;
 	&lt;br /&gt;
 	public RunLengthEncoding(Ocean sea) {&lt;br /&gt;
 		int is=0;&lt;br /&gt;
 		int ir=1;&lt;br /&gt;
 		int seasize = sea.width()*sea.height();&lt;br /&gt;
 		rle = new DList(sea.width(), sea.height(), sea.starveTime());&lt;br /&gt;
 		while (is&amp;lt;seasize) {&lt;br /&gt;
 			int tip = sea.cellContents(sea.coordx(is), sea.coordy(is));&lt;br /&gt;
 			int hunger = sea.sharkFeeding(is);&lt;br /&gt;
 			rle.insertEnd(tip, 1, hunger);&lt;br /&gt;
 			is++;&lt;br /&gt;
 			for (; sea.cellContents(sea.coordx(is), sea.coordy(is)) == tip &amp;amp;&amp;amp; sea.sharkFeeding(is) == hunger &amp;amp;&amp;amp; is&amp;lt;seasize; is++) {&lt;br /&gt;
 				rle.nth(ir).type = tip;&lt;br /&gt;
 				rle.nth(ir).consecs++;&lt;br /&gt;
 				rle.nth(ir).hunger = hunger;&lt;br /&gt;
 			}&lt;br /&gt;
 			ir++;&lt;br /&gt;
 		}&lt;br /&gt;
 		runsleft = ir-1;&lt;br /&gt;
 		check();&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  The following methods are required for Part IV.&lt;br /&gt;
 	 */&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  addFish() places a fish in cell (x, y) if the cell is empty.  If the&lt;br /&gt;
 	 *  cell is already occupied, leave the cell as it is.  The final run-length&lt;br /&gt;
 	 *  encoding should be compressed as much as possible; there should not be&lt;br /&gt;
 	 *  two consecutive runs of sharks with the same degree of hunger.&lt;br /&gt;
 	 *  @param x is the x-coordinate of the cell to place a fish in.&lt;br /&gt;
 	 *  @param y is the y-coordinate of the cell to place a fish in.&lt;br /&gt;
 	 */&lt;br /&gt;
 	&lt;br /&gt;
 	// This helper helps us convert (x,y) into a single-digit position but is slightly modified from the version in Ocean.java to work with RLEs&lt;br /&gt;
 	public int itempos(int x, int y) {&lt;br /&gt;
 		x = x%rle.dimx;&lt;br /&gt;
 		y = y%rle.dimy;&lt;br /&gt;
 		if (x &amp;lt; 0) { x = x+rle.dimx; }&lt;br /&gt;
 		if (y &amp;lt; 0) { y = y+rle.dimy; }&lt;br /&gt;
 		int ind = (rle.dimx*y+x) + 1;&lt;br /&gt;
 		return ind;&lt;br /&gt;
 	}&lt;br /&gt;
 &lt;br /&gt;
 	public void addFish(int x, int y) {&lt;br /&gt;
 		int index = itempos(x, y);&lt;br /&gt;
 		int rlepos = 1;&lt;br /&gt;
 		int i = 1;&lt;br /&gt;
 		for (; i&amp;lt;rle.length(); i++) {&lt;br /&gt;
 			rlepos = rlepos + rle.nth(i).consecs;&lt;br /&gt;
 			if (rlepos &amp;gt; index) { &lt;br /&gt;
 				rlepos = rlepos - rle.nth(i).consecs - 1;&lt;br /&gt;
 				break; }&lt;br /&gt;
 		}&lt;br /&gt;
 		if (i&amp;gt;=rle.length()) { System.out.println(&amp;quot;Something terribly wrong happened, sorry...&amp;quot;); }&lt;br /&gt;
 		else if (rle.nth(i).type != Ocean.EMPTY) { System.out.println(&amp;quot;Destination cell is not empty&amp;quot;); }&lt;br /&gt;
 		else actualinsertion: { &lt;br /&gt;
 			DListNode removednode = rle.nth(i);&lt;br /&gt;
 			int after = removednode.consecs - (index - rlepos);&lt;br /&gt;
 			int before = removednode.consecs - after - 1;&lt;br /&gt;
 			DListNode insertionnode = new DListNode(Ocean.FISH);&lt;br /&gt;
 			insertionnode.consecs = 1;&lt;br /&gt;
 			DListNode beforenode;&lt;br /&gt;
 			DListNode afternode;&lt;br /&gt;
 			boolean nodeisgone = false;&lt;br /&gt;
 			if (after==0 &amp;amp;&amp;amp; removednode.next.type==Ocean.FISH &amp;amp;&amp;amp; removednode.prev.type!=Ocean.FISH) { // there are no empty spaces, following block is a fish, and previous block is NOT a fish&lt;br /&gt;
 				removednode.next.consecs++;&lt;br /&gt;
 				nodeisgone = true;&lt;br /&gt;
 			}  if (before==0 &amp;amp;&amp;amp; removednode.prev.type==Ocean.FISH &amp;amp;&amp;amp; removednode.next.type!=Ocean.FISH) { // there are no empty spaces, previous block is fish, and following block is NOT fish&lt;br /&gt;
 				removednode.prev.consecs++;&lt;br /&gt;
 				nodeisgone = true;&lt;br /&gt;
 			} if (after==0 &amp;amp;&amp;amp; before==0 &amp;amp;&amp;amp; removednode.prev.type!=Ocean.FISH &amp;amp;&amp;amp; removednode.next.type!=Ocean.FISH) { // this cell is nestled between two blocks neither of which is a fish&lt;br /&gt;
 				insertionnode.next = removednode.next;&lt;br /&gt;
 				insertionnode.next.prev = insertionnode;&lt;br /&gt;
 				insertionnode.prev = removednode.prev;&lt;br /&gt;
 				insertionnode.prev.next = insertionnode;&lt;br /&gt;
 				// we're done here&lt;br /&gt;
 				break actualinsertion;&lt;br /&gt;
 			} if (removednode.next.type==Ocean.FISH &amp;amp;&amp;amp; removednode.prev.type==Ocean.FISH) { // both previous and next blocks contain fish, so we need to combine three blocks into one&lt;br /&gt;
 				int combination = removednode.next.consecs + removednode.prev.consecs + 1;&lt;br /&gt;
 				DListNode overhaul = new DListNode(Ocean.FISH);&lt;br /&gt;
 				overhaul.consecs = combination;&lt;br /&gt;
 				overhaul.next = removednode.next.next;&lt;br /&gt;
 				overhaul.next.prev = overhaul;&lt;br /&gt;
 				overhaul.prev = removednode.prev.prev;&lt;br /&gt;
 				overhaul.prev.next = overhaul;&lt;br /&gt;
 				rle.size = rle.size -2;&lt;br /&gt;
 				runsleft = rle.length();&lt;br /&gt;
 				// we're done here&lt;br /&gt;
 				break actualinsertion;&lt;br /&gt;
 			} if (nodeisgone) { // if as a result of the previous testcases, our initially created node is no longer needed (nodeisgone == true), we need to combine the before and after frequencies, make a single new node, and link it to the list appropriately&lt;br /&gt;
 				int combined = after + before;&lt;br /&gt;
 				if (combined &amp;gt; 0) {&lt;br /&gt;
 					DListNode superduper = new DListNode(Ocean.EMPTY);&lt;br /&gt;
 					superduper.consecs = combined;&lt;br /&gt;
 					superduper.next = removednode.next;&lt;br /&gt;
 					superduper.prev = removednode.prev;&lt;br /&gt;
 					superduper.prev.next = superduper;&lt;br /&gt;
 					superduper.next.prev = superduper;&lt;br /&gt;
 				} else {&lt;br /&gt;
 					removednode.prev.next = removednode.next;&lt;br /&gt;
 					removednode.next.prev = removednode.prev;&lt;br /&gt;
 					rle.size--;&lt;br /&gt;
 				}&lt;br /&gt;
 			}  else if (before&amp;gt;0 || after&amp;gt;0) {&lt;br /&gt;
 				if (before &amp;gt; 0) { // there are still some empty spaces before this fish&lt;br /&gt;
 					beforenode = new DListNode(Ocean.EMPTY);&lt;br /&gt;
 					beforenode.consecs = before;&lt;br /&gt;
 					beforenode.prev = removednode.prev;&lt;br /&gt;
 					removednode.prev.next = beforenode;&lt;br /&gt;
 					beforenode.next = insertionnode;&lt;br /&gt;
 					insertionnode.prev = beforenode;&lt;br /&gt;
 					if (after == 0) {&lt;br /&gt;
 						insertionnode.next = removednode.next;&lt;br /&gt;
 						insertionnode.next.prev = insertionnode; }&lt;br /&gt;
 					rle.size++;&lt;br /&gt;
 					runsleft = rle.length();&lt;br /&gt;
 				} if (after &amp;gt; 0) { // there are still some empty spaces after this fish&lt;br /&gt;
 					afternode = new DListNode(Ocean.EMPTY);&lt;br /&gt;
 					afternode.consecs = after;&lt;br /&gt;
 					afternode.next = removednode.next;&lt;br /&gt;
 					afternode.next.prev = afternode;&lt;br /&gt;
 					insertionnode.next = afternode;&lt;br /&gt;
 					if (before == 0) {&lt;br /&gt;
 						insertionnode.prev = removednode.prev;&lt;br /&gt;
 						insertionnode.prev.next = insertionnode; }&lt;br /&gt;
 					afternode.prev = insertionnode;&lt;br /&gt;
 					rle.size++;&lt;br /&gt;
 					runsleft = rle.length();&lt;br /&gt;
 				}&lt;br /&gt;
 			}&lt;br /&gt;
 		}&lt;br /&gt;
 		check();&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  addShark() (with two parameters) places a newborn shark in cell (x, y) if&lt;br /&gt;
 	 *  the cell is empty.  A &amp;quot;newborn&amp;quot; shark is equivalent to a shark that has&lt;br /&gt;
 	 *  just eaten.  If the cell is already occupied, leave the cell as it is.&lt;br /&gt;
 	 *  The final run-length encoding should be compressed as much as possible;&lt;br /&gt;
 	 *  there should not be two consecutive runs of sharks with the same degree&lt;br /&gt;
 	 *  of hunger.&lt;br /&gt;
 	 *  @param x is the x-coordinate of the cell to place a shark in.&lt;br /&gt;
 	 *  @param y is the y-coordinate of the cell to place a shark in.&lt;br /&gt;
 	 */&lt;br /&gt;
 	&lt;br /&gt;
 	public void addShark(int x, int y) {&lt;br /&gt;
 		int index = itempos(x, y);&lt;br /&gt;
 		int rlepos = 1;&lt;br /&gt;
 		int i = 1;&lt;br /&gt;
 		for (; i&amp;lt;rle.length(); i++) {&lt;br /&gt;
 			rlepos = rlepos + rle.nth(i).consecs;&lt;br /&gt;
 			if (rlepos &amp;gt; index) { &lt;br /&gt;
 				rlepos = rlepos - rle.nth(i).consecs - 1;&lt;br /&gt;
 				break; }&lt;br /&gt;
 		}&lt;br /&gt;
 		if (i&amp;gt;=rle.length()) { System.out.println(&amp;quot;Something terribly wrong happened, sorry...&amp;quot;); }&lt;br /&gt;
 		else if (rle.nth(i).type != Ocean.EMPTY) { System.out.println(&amp;quot;Destination cell is not empty&amp;quot;); }&lt;br /&gt;
 		else actualinsertion: { &lt;br /&gt;
 			DListNode removednode = rle.nth(i);&lt;br /&gt;
 			int destinationhunger = rle.starvetime;&lt;br /&gt;
 			int after = removednode.consecs - (index - rlepos);&lt;br /&gt;
 			int before = removednode.consecs - after - 1;&lt;br /&gt;
 			DListNode insertionnode = new DListNode(Ocean.SHARK, destinationhunger);&lt;br /&gt;
 			insertionnode.consecs = 1;&lt;br /&gt;
 			DListNode beforenode;&lt;br /&gt;
 			DListNode afternode;&lt;br /&gt;
 			boolean nodeisgone = false;&lt;br /&gt;
 			if (after==0 &amp;amp;&amp;amp; removednode.next.type==Ocean.SHARK &amp;amp;&amp;amp; removednode.next.hunger==destinationhunger &amp;amp;&amp;amp; removednode.prev.hunger!=destinationhunger) { // there are no empty spaces, following block is a shark with the same hunger, and previous block is NOT a shark with the same hunger&lt;br /&gt;
 				removednode.next.consecs++;&lt;br /&gt;
 				nodeisgone = true;&lt;br /&gt;
 			}  if (before==0 &amp;amp;&amp;amp; removednode.prev.type==Ocean.SHARK &amp;amp;&amp;amp; removednode.prev.hunger==destinationhunger &amp;amp;&amp;amp; removednode.next.hunger!=destinationhunger) { // there are no empty spaces, previous block is a shark with the same hunger, and following block is NOT a shark with the same hunger&lt;br /&gt;
 				removednode.prev.consecs++;&lt;br /&gt;
 				nodeisgone = true;&lt;br /&gt;
 			} if (after==0 &amp;amp;&amp;amp; before==0 &amp;amp;&amp;amp; removednode.prev.hunger!=destinationhunger &amp;amp;&amp;amp; removednode.next.hunger!=destinationhunger) { // this cell is nestled between two blocks that differ from the shark we're inserting.&lt;br /&gt;
 				insertionnode.next = removednode.next;&lt;br /&gt;
 				insertionnode.next.prev = insertionnode;&lt;br /&gt;
 				insertionnode.prev = removednode.prev;&lt;br /&gt;
 				insertionnode.prev.next = insertionnode;&lt;br /&gt;
 				// we're done here&lt;br /&gt;
 				break actualinsertion;&lt;br /&gt;
 			} if (after==0 &amp;amp;&amp;amp; before==0 &amp;amp;&amp;amp; removednode.next.type==Ocean.SHARK &amp;amp;&amp;amp; removednode.prev.type==Ocean.SHARK &amp;amp;&amp;amp; removednode.next.hunger==destinationhunger &amp;amp;&amp;amp; removednode.prev.hunger==destinationhunger) { // we're inserting into a cell surrounded by blocks of sharks both of which have the same hunger levels, so we need to combine three blocks into one&lt;br /&gt;
 				int combination = removednode.next.consecs + removednode.prev.consecs + 1;&lt;br /&gt;
 				DListNode overhaul = new DListNode(Ocean.SHARK, destinationhunger);&lt;br /&gt;
 				overhaul.consecs = combination;&lt;br /&gt;
 				overhaul.next = removednode.next.next;&lt;br /&gt;
 				overhaul.next.prev = overhaul;&lt;br /&gt;
 				overhaul.prev = removednode.prev.prev;&lt;br /&gt;
 				overhaul.prev.next = overhaul;&lt;br /&gt;
 				rle.size = rle.size -2;&lt;br /&gt;
 				runsleft = rle.length();&lt;br /&gt;
 				// we're done here&lt;br /&gt;
 				break actualinsertion;&lt;br /&gt;
 			} if (nodeisgone) { // if as a result of the previous testcases, our initially created node is no longer needed (nodeisgone == true), we need to combine the before and after frequencies, make a single new node, and link it to the list appropriately&lt;br /&gt;
 				int combined = after + before;&lt;br /&gt;
 				if (combined &amp;gt; 0) {&lt;br /&gt;
 					DListNode superduper = new DListNode(Ocean.EMPTY);&lt;br /&gt;
 					superduper.consecs = combined;&lt;br /&gt;
 					superduper.next = removednode.next;&lt;br /&gt;
 					superduper.prev = removednode.prev;&lt;br /&gt;
 					superduper.prev.next = superduper;&lt;br /&gt;
 					superduper.next.prev = superduper;&lt;br /&gt;
 				} else {&lt;br /&gt;
 					removednode.prev.next = removednode.next;&lt;br /&gt;
 					removednode.next.prev = removednode.prev;&lt;br /&gt;
 					rle.size--;&lt;br /&gt;
 				}&lt;br /&gt;
 			} else if (before&amp;gt;0 || after&amp;gt;0) {&lt;br /&gt;
 				if (before &amp;gt; 0) { // there are still some empty spaces before this shark or there are sharks but with different hunger levels&lt;br /&gt;
 					beforenode = new DListNode(Ocean.EMPTY);&lt;br /&gt;
 					beforenode.consecs = before;&lt;br /&gt;
 					beforenode.prev = removednode.prev;&lt;br /&gt;
 					removednode.prev.next = beforenode;&lt;br /&gt;
 					beforenode.next = insertionnode;&lt;br /&gt;
 					insertionnode.prev = beforenode;&lt;br /&gt;
 					if (after == 0) {&lt;br /&gt;
 						insertionnode.next = removednode.next;&lt;br /&gt;
 						insertionnode.next.prev = insertionnode; }&lt;br /&gt;
 					rle.size++;&lt;br /&gt;
 					runsleft = rle.length();&lt;br /&gt;
 				} if (after &amp;gt; 0) { // there are still some empty spaces after this shark or there are sharks but with different hunger levels&lt;br /&gt;
 					afternode = new DListNode(Ocean.EMPTY);&lt;br /&gt;
 					afternode.consecs = after;&lt;br /&gt;
 					afternode.next = removednode.next;&lt;br /&gt;
 					afternode.next.prev = afternode;&lt;br /&gt;
 					insertionnode.next = afternode;&lt;br /&gt;
 					if (before == 0) {&lt;br /&gt;
 						insertionnode.prev = removednode.prev;&lt;br /&gt;
 						insertionnode.prev.next = insertionnode; }&lt;br /&gt;
 					afternode.prev = insertionnode;&lt;br /&gt;
 					rle.size++;&lt;br /&gt;
 					runsleft = rle.length();&lt;br /&gt;
 				}&lt;br /&gt;
 			} &lt;br /&gt;
 		}&lt;br /&gt;
 		check();&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 	/**&lt;br /&gt;
 	 *  check() walks through the run-length encoding and prints an error message&lt;br /&gt;
 	 *  if two consecutive runs have the same contents, or if the sum of all run&lt;br /&gt;
 	 *  lengths does not equal the number of cells in the ocean.&lt;br /&gt;
 	 */&lt;br /&gt;
 	&lt;br /&gt;
 	public void check() {&lt;br /&gt;
 		int ti = 0;&lt;br /&gt;
 		for (int i=1; i&amp;lt;rle.length(); i++) {&lt;br /&gt;
 			if (rle.nth(i).type == rle.nth(i+1).type &amp;amp;&amp;amp; rle.nth(i).hunger == rle.nth(i+1).hunger) {&lt;br /&gt;
 				System.out.print(&amp;quot;I've found a bug! You have the same type of cells in two consecutive RLE nodes! Problem is at nodes &amp;quot; + i + &amp;quot; and &amp;quot; + (i+1) + &amp;quot;\n&amp;quot;);&lt;br /&gt;
 			}&lt;br /&gt;
 		}&lt;br /&gt;
 		for (int ii=1; ii&amp;lt;=rle.length(); ii++) {&lt;br /&gt;
 			ti = ti + rle.nth(ii).consecs;&lt;br /&gt;
 		}	&lt;br /&gt;
 		if (ti != rle.dimx*rle.dimy) {&lt;br /&gt;
 			System.out.print(&amp;quot;I've found a bug! The sum of run lengths is NOT equal to the Ocean's size - runlengths is &amp;quot; + ti + &amp;quot; vs Ocean size of &amp;quot; + (rle.dimx*rle.dimy) + &amp;quot;\n&amp;quot;);&lt;br /&gt;
 		}&lt;br /&gt;
 	}&lt;br /&gt;
 	&lt;br /&gt;
 }&lt;/div&gt;</summary>
		<author><name>Lensovet</name></author>
		
	</entry>
</feed>