相关疑难解决方法(0)

在perl中访问json结构的值

我有一个json结构,我正在解码,看起来像这样:

  person => {
    city => "Chicago",
    id => 123,
    name => "Joe Smith",
    pets => {
      cats => [
                { age => 6, name => "cat1", type => "siamese", weight => "10 kilos" },
                { age => 10, name => "cat2", type => "siamese", weight => "13 kilos" },
              ],
      dogs => [
                { age => 7, name => "dog1", type => "siamese", weight => "20 kilos" },
                { age => 5, name => "dog2", type => "siamese", weight …
Run Code Online (Sandbox Code Playgroud)

perl hash json hash-of-hashes

4
推荐指数
2
解决办法
2万
查看次数

标签 统计

hash ×1

hash-of-hashes ×1

json ×1

perl ×1