Skip to content

Instantly share code, notes, and snippets.

View jaredpar's full-sized avatar

Jared Parsons jaredpar

View GitHub Profile
def main():
#Declare
price = 99
quantity = float(input("How many packages have you purchased?"))
if quantity >= 10:
print ("Your discount is 20%.")
package com.koushikdutta.async;
import java.io.IOException;
import java.nio.channels.SelectionKey;
import java.nio.channels.Selector;
import java.util.Set;
import java.util.concurrent.Semaphore;
import java.util.concurrent.TimeUnit;
/**
/// <summary>
/// This will get the text of the ITextView line as it appears in the actual user editable
/// document.
/// </summary>
public static bool TryGetText(ITextView textView, ITextViewLine textViewLine, out string text)
{
var extent = textViewLine.Extent;
var bufferGraph = textView.BufferGraph;
try
{
/// <summary>
/// This will get the text of the ITextView line as it appears in the actual user editable
/// document.
/// </summary>
public static bool TryGetText(ITextView textView, ITextViewLine textViewLine, out string text)
{
var extent = textViewLine.Extent;
var bufferGraph = textView.BufferGraph;
try
{