Recent Activity

Activity List

  • Welcome Aboard!
    May 23
  • base2, RickDoll and warsau67 joined.
    Welcome Aboard!
    May 21
  • Welcome Aboard!
    May 17
  • Ifrit joined.
    Welcome Aboard!
    May 13
  • MCleeren and evirts joined.
    Welcome Aboard!
    May 9
  • rdavisau joined.
    Welcome Aboard!
    May 6
  • njones joined.
    Welcome Aboard!
    May 4
  • AdamRene joined.
    Welcome Aboard!
    May 2
  • kmataru joined.
    Welcome Aboard!
    April 24
  • brennon and shikr joined.
    Welcome Aboard!
    April 23
  • //Am I missing a reference in LinqPad?
    //I get an error in LinqPad on line 9 below from Listing 2-14. Generate Logo commands to draw a //Serpinski triangle.linq:

    //"CS0103 The name 'serpinskyTriangle' does not exist in the current context"
    1. string serpinskiTriangle = "A";
    2. Func transformA = x => x.Replace("A","B-A-B");
    3. Func markBs = x => x.Replace("B","[B]");
    4. Func transformB = x => x.Replace("[B]","A+B+A");
    5. int length = 6;
    6. Enumerable.Range(1,length)
    7. .ToList()
    8. .ForEach (k => serpinskiTriangle =
    9. transformB(transformA(markBs(serpinskyTriangle))));

    10. serpinskiTriangle
    11. .Replace("A", "forward 5" + Environment.NewLine)
    12. .Replace("B", "forward 5" + Environment.NewLine)
    13. .Replace("+", "left 60" + Environment.NewLine)
    14. .Replace("-", "right 60" + Environment.NewLine)
    15. .Dump("LOGO Commands for drawing Serpinsky Triangle");
    // Thanks!
    // Gregg
    April 19
    • nescafe
      nescafe
      It's a simple spelling error. serpinskyTriangle is not declared. serpinskiTriangle is (y=i). Please post your question in the Discussions section next time, it will be picked up sooner than in the Activity section

      Script: http://share.linqpad.net/4477wp.linq

      Result:
    • nescafe
      nescafe
      https://lh3.googleusercontent.com/oIf3WEdmwQA0POLF291KMtRtI8ysyEyA2ei9qj7rii2LvPR8CA82rR_E49vv1szumAShOjs9nbb76WOnNMv8-Uhss47-_2MjnV5cM6hE1OqvSX_TPhZa9-UZ6-ExeciqGo_3G5jjCg1VmBy30dhpB_Cb3x7NWYVB54GGzdEdwaHm7PhCFN82dpDSbsOCl5LZDKPOZgSzowzem1oOzuLXqHmJuxOPHAJQLvewZKdOdLDMSFkqx3yvHcSWoDXpesmYvwjUo5CybYr9eFiMJjdlRDp3SvogbO__fTK6eMdmH0OO9uES5toRD2vROnIkDGXLAvbDAYqsLBpzswLy5L6S3dXz1EsewsVSAxYaUhl8w0dJ9ioAVzaN-u4f0CLpC1ePX6j9jynYvE8kgfQsAUyO5-JMhgy5dbqT2blFao2K0NjlUJz-QwLotapRYiVZTc-jMAgQBJ_yc0RHXrqn-Ep7v1JTyzt3FeqmSfoWwSWVsr2KXEm-Yyz5OyPjBsGNOBk2rftDFB8vkC5p2i_HYJ7GNiBcxkkJBI9C0dsKpc75stlMohvns9kMnakh1C1QlFqKGWvN-27OWMZUEknh2_Mi9xhIcZSVnLVIZ2yJjiGNvxHaq1cKsXSTL-f1iA88p8U7OXjon17P90MFKPTY4M1N_Ai7fhbl32-FhJNoylUOTzBUTFstjtn_oTqr1OFN2zcA03kPJyKvMT-EmebreF-0tdKmPQLSZMdTsYmX4AjWT637UvP0-IIZnjXBvj6hzL7W_JcekKc09yVFz65J0hxkSn9ioxvr0nx_aXrkUHri0zRFRi1EQQsjQD1N=w315-h371-no
    • nescafe
      nescafe
      Image generated using https://www.calormen.com/jslogo/
    • gmazel
      gmazel
      Thank you!
  • Welcome Aboard!
    April 21
  • desjarlu joined.
    Welcome Aboard!
    April 19
  • jhorv joined.
    Welcome Aboard!
    April 18
  • lszoke and WalterG joined.
    Welcome Aboard!
    April 15
  • pjsmith01 joined.
    Welcome Aboard!
    April 14
  • Welcome Aboard!
    April 11
  • Welcome Aboard!
    April 9
  • thedavegray and Papst earned the First Comment badge.
    Commenting is the best way to get involved. Jump in the fray!
    April 9
  • Papst earned the First Anniversary badge.
    Thanks for sticking with us for a full year.
    April 9
  • Papst earned the Second Anniversary badge.
    Thanks for sticking with us for 2 years.
    April 9
  • Papst earned the Third Anniversary badge.
    Thanks for sticking with us for 3 years.
    April 9
  • Papst earned the Fourth Anniversary badge.
    Thanks for sticking with us for 4 years.
    April 9
  • stevensrmiller earned the First Comment badge.
    Commenting is the best way to get involved. Jump in the fray!
    April 7
  • Welcome Aboard!
    April 7
  • SteveCrane earned the Second Anniversary badge.
    Thanks for sticking with us for 2 years.
    April 6
  • SteveCrane earned the Third Anniversary badge.
    Thanks for sticking with us for 3 years.
    April 6
  • SteveCrane earned the Fourth Anniversary badge.
    Thanks for sticking with us for 4 years.
    April 6
  • Thanks for sticking with us for 7 years.
    April 6
  • msGuy earned the First Anniversary badge.
    Thanks for sticking with us for a full year.
    April 6

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!